summaryrefslogtreecommitdiffstats
path: root/smenu.1
diff options
context:
space:
mode:
authorpgen <p.gen.progs@gmail.com>2023-06-21 23:57:20 +0200
committerpgen <p.gen.progs@gmail.com>2023-06-21 23:57:20 +0200
commita3044266f398018ae0eb250e59779ca38aef52a3 (patch)
tree5678c6a6da8b58e940ee9fe73f4ca9fedf13bcc2 /smenu.1
parenta28220698d7857ab9d2b3b64ab53740b0ca4a7a8 (diff)
Add a new example to the manual
Diffstat (limited to 'smenu.1')
-rw-r--r--smenu.111
1 files changed, 11 insertions, 0 deletions
diff --git a/smenu.1 b/smenu.1
index e578a4e..1a2986d 100644
--- a/smenu.1
+++ b/smenu.1
@@ -1465,6 +1465,17 @@ Only the numbered word(s) will be prefixed.
This directive can be useful when you want to post-process the output
according to its direct access number.
+
+Example:
+.br
+\f(CBR=$(echo a b c | smenu -N -D d:-)\fR
+.br
+will display:
+.br
+\f(CB1)\f(CR a \f(CB2)\f(CR b \f(CB3)\f(CR c\fR
+.br
+The variable \f(CBR\fP will then contain the string \f(CB2-b\fP if
+\f(CBb\fP is selected.
.
.TP
\f(CBs\fP (\fB-F\fP|\fB-en\fP|\fB-embedded_number\fP, \