@@ -24,7 +24,7 @@ this into complete documentation for the library, with examples, over time):
2424 By default, options are toggles that default to nil, but the second string
2525 parameter may be used to specify that an option requires an argument.
2626
27- e.g. [\ "-p\" \ "--port PORT\ "] specifies that --port requires an argument,
27+ e.g. ["-p" "--port PORT"] specifies that --port requires an argument,
2828 of which PORT is a short description.
2929
3030 The :property value pairs are optional and take precedence over the
@@ -38,17 +38,18 @@ this into complete documentation for the library, with examples, over time):
3838 transform a value in different ways, but only one of these
3939 option entries may contain a :default(-fn) entry.
4040
41- This option is mandatory.
41+ This option is mandatory if no long option is provided .
4242
4343 :short-opt The short format for this option, normally set by the first
44- positional string parameter: e.g. \ "-p\ ". Must be unique.
44+ positional string parameter: e.g. "-p". Must be unique.
4545
4646 :long-opt The long format for this option, normally set by the second
47- positional string parameter; e.g. \ "--port\ ". Must be unique.
47+ positional string parameter; e.g. "--port". Must be unique.
4848
4949 :required A description of the required argument for this option if
5050 one is required; normally set in the second positional
51- string parameter after the long option: \"--port PORT\".
51+ string parameter after the long option: "--port PORT",
52+ which would be equivalent to :required "PORT".
5253
5354 The absence of this entry indicates that the option is a
5455 boolean toggle that is set to true when specified on the
@@ -93,7 +94,7 @@ this into complete documentation for the library, with examples, over time):
9394 If this is a boolean option, parse-fn will receive the value
9495 true. This may be used to invert the logic of this option:
9596
96- [\ "-q\" \ "--quiet\ "
97+ ["-q" "--quiet"
9798 :id :verbose
9899 :default true
99100 :parse-fn not]
@@ -118,16 +119,16 @@ this into complete documentation for the library, with examples, over time):
118119
119120 This may be used to create non-idempotent options where you
120121 only need the current value, like setting a verbosity level by
121- specifying an option multiple times. (\ "-vvv\ " -> 3)
122+ specifying an option multiple times. ("-vvv" -> 3)
122123
123- [\ "-v\" \ "--verbose\ "
124+ ["-v" "--verbose"
124125 :default 0
125126 :update-fn inc]
126127
127128 :default is applied first. If you wish to omit the :default
128129 option value, use fnil in your :update-fn as follows:
129130
130- [\ "-v\" \ "--verbose\ "
131+ ["-v" "--verbose"
131132 :update-fn (fnil inc 0)]
132133
133134 With :multi true:
@@ -141,15 +142,15 @@ this into complete documentation for the library, with examples, over time):
141142 value based on the current value and a new value from the
142143 command line. This can sometimes be easier than use :assoc-fn.
143144
144- [\ "-f\" \ "--file NAME\ "
145+ ["-f" "--file NAME"
145146 :default []
146147 :update-fn conj
147148 :multi true]
148149
149150 :default is applied first. If you wish to omit the :default
150151 option value, use fnil in your :update-fn as follows:
151152
152- [\ "-f\" \ "--file NAME\ "
153+ ["-f" "--file NAME"
153154 :update-fn (fnil conj [])
154155 :multi true]
155156
0 commit comments