1ZSHOPTIONS(1) General Commands Manual ZSHOPTIONS(1)
2
3
4
6 zshoptions - zsh options
7
9 Options are primarily referred to by name. These names are case insen‐
10 sitive and underscores are ignored. For example, `allexport' is equiv‐
11 alent to `A__lleXP_ort'.
12
13 The sense of an option name may be inverted by preceding it with `no',
14 so `setopt No_Beep' is equivalent to `unsetopt beep'. This inversion
15 can only be done once, so `nonobeep' is not a synonym for `beep'. Sim‐
16 ilarly, `tify' is not a synonym for `nonotify' (the inversion of
17 `notify').
18
19 Some options also have one or more single letter names. There are two
20 sets of single letter options: one used by default, and another used to
21 emulate sh/ksh (used when the SH_OPTION_LETTERS option is set). The
22 single letter options can be used on the shell command line, or with
23 the set, setopt and unsetopt builtins, as normal Unix options preceded
24 by `-'.
25
26 The sense of the single letter options may be inverted by using `+'
27 instead of `-'. Some of the single letter option names refer to an
28 option being off, in which case the inversion of that name refers to
29 the option being on. For example, `+n' is the short name of `exec',
30 and `-n' is the short name of its inversion, `noexec'.
31
32 In strings of single letter options supplied to the shell at startup,
33 trailing whitespace will be ignored; for example the string `-f '
34 will be treated just as `-f', but the string `-f i' is an error. This
35 is because many systems which implement the `#!' mechanism for calling
36 scripts do not strip trailing whitespace.
37
39 In the following list, options set by default in all emulations are
40 marked <D>; those set by default only in csh, ksh, sh, or zsh emula‐
41 tions are marked <C>, <K>, <S>, <Z> as appropriate. When listing
42 options (by `setopt', `unsetopt', `set -o' or `set +o'), those turned
43 on by default appear in the list prefixed with `no'. Hence (unless
44 KSH_OPTION_PRINT is set), `setopt' shows all options whose settings are
45 changed from the default.
46
47 Changing Directories
48 AUTO_CD (-J)
49 If a command is issued that can't be executed as a normal com‐
50 mand, and the command is the name of a directory, perform the cd
51 command to that directory.
52
53 AUTO_PUSHD (-N)
54 Make cd push the old directory onto the directory stack.
55
56 CDABLE_VARS (-T)
57 If the argument to a cd command (or an implied cd with the
58 AUTO_CD option set) is not a directory, and does not begin with
59 a slash, try to expand the expression as if it were preceded by
60 a `~' (see the section `Filename Expansion').
61
62 CHASE_DOTS
63 When changing to a directory containing a path segment `..'
64 which would otherwise be treated as canceling the previous seg‐
65 ment in the path (in other words, `foo/..' would be removed from
66 the path, or if `..' is the first part of the path, the last
67 part of $PWD would be deleted), instead resolve the path to the
68 physical directory. This option is overridden by CHASE_LINKS.
69
70 For example, suppose /foo/bar is a link to the directory
71 /alt/rod. Without this option set, `cd /foo/bar/..' changes to
72 /foo; with it set, it changes to /alt. The same applies if the
73 current directory is /foo/bar and `cd ..' is used. Note that
74 all other symbolic links in the path will also be resolved.
75
76 CHASE_LINKS (-w)
77 Resolve symbolic links to their true values when changing direc‐
78 tory. This also has the effect of CHASE_DOTS, i.e. a `..' path
79 segment will be treated as referring to the physical parent,
80 even if the preceding path segment is a symbolic link.
81
82 PUSHD_IGNORE_DUPS
83 Don't push multiple copies of the same directory onto the direc‐
84 tory stack.
85
86 PUSHD_MINUS
87 Exchanges the meanings of `+' and `-' when used with a number to
88 specify a directory in the stack.
89
90 PUSHD_SILENT (-E)
91 Do not print the directory stack after pushd or popd.
92
93 PUSHD_TO_HOME (-D)
94 Have pushd with no arguments act like `pushd $HOME'.
95
96 Completion
97 ALWAYS_LAST_PROMPT <D>
98 If unset, key functions that list completions try to return to
99 the last prompt if given a numeric argument. If set these func‐
100 tions try to return to the last prompt if given no numeric argu‐
101 ment.
102
103 ALWAYS_TO_END
104 If a completion is performed with the cursor within a word, and
105 a full completion is inserted, the cursor is moved to the end of
106 the word. That is, the cursor is moved to the end of the word
107 if either a single match is inserted or menu completion is per‐
108 formed.
109
110 AUTO_LIST (-9) <D>
111 Automatically list choices on an ambiguous completion.
112
113 AUTO_MENU <D>
114 Automatically use menu completion after the second consecutive
115 request for completion, for example by pressing the tab key
116 repeatedly. This option is overridden by MENU_COMPLETE.
117
118 AUTO_NAME_DIRS
119 Any parameter that is set to the absolute name of a directory
120 immediately becomes a name for that directory, that will be used
121 by the `%~' and related prompt sequences, and will be available
122 when completion is performed on a word starting with `~'. (Oth‐
123 erwise, the parameter must be used in the form `~param' first.)
124
125 AUTO_PARAM_KEYS <D>
126 If a parameter name was completed and a following character
127 (normally a space) automatically inserted, and the next charac‐
128 ter typed is one of those that have to come directly after the
129 name (like `}', `:', etc.), the automatically added character is
130 deleted, so that the character typed comes immediately after the
131 parameter name. Completion in a brace expansion is affected
132 similarly: the added character is a `,', which will be removed
133 if `}' is typed next.
134
135 AUTO_PARAM_SLASH <D>
136 If a parameter is completed whose content is the name of a
137 directory, then add a trailing slash instead of a space.
138
139 AUTO_REMOVE_SLASH <D>
140 When the last character resulting from a completion is a slash
141 and the next character typed is a word delimiter, a slash, or a
142 character that ends a command (such as a semicolon or an amper‐
143 sand), remove the slash.
144
145 BASH_AUTO_LIST
146 On an ambiguous completion, automatically list choices when the
147 completion function is called twice in succession. This takes
148 precedence over AUTO_LIST. The setting of LIST_AMBIGUOUS is
149 respected. If AUTO_MENU is set, the menu behaviour will then
150 start with the third press. Note that this will not work with
151 MENU_COMPLETE, since repeated completion calls immediately cycle
152 through the list in that case.
153
154 COMPLETE_ALIASES
155 Prevents aliases on the command line from being internally sub‐
156 stituted before completion is attempted. The effect is to make
157 the alias a distinct command for completion purposes.
158
159 COMPLETE_IN_WORD
160 If unset, the cursor is set to the end of the word if completion
161 is started. Otherwise it stays there and completion is done from
162 both ends.
163
164 GLOB_COMPLETE
165 When the current word has a glob pattern, do not insert all the
166 words resulting from the expansion but generate matches as for
167 completion and cycle through them like MENU_COMPLETE. The
168 matches are generated as if a `*' was added to the end of the
169 word, or inserted at the cursor when COMPLETE_IN_WORD is set.
170 This actually uses pattern matching, not globbing, so it works
171 not only for files but for any completion, such as options, user
172 names, etc.
173
174 Note that when the pattern matcher is used, matching control
175 (for example, case-insensitive or anchored matching) cannot be
176 used. This limitation only applies when the current word con‐
177 tains a pattern; simply turning on the GLOB_COMPLETE option does
178 not have this effect.
179
180 HASH_LIST_ALL <D>
181 Whenever a command completion is attempted, make sure the entire
182 command path is hashed first. This makes the first completion
183 slower.
184
185 LIST_AMBIGUOUS <D>
186 This option works when AUTO_LIST or BASH_AUTO_LIST is also set.
187 If there is an unambiguous prefix to insert on the command line,
188 that is done without a completion list being displayed; in other
189 words, auto-listing behaviour only takes place when nothing
190 would be inserted. In the case of BASH_AUTO_LIST, this means
191 that the list will be delayed to the third call of the function.
192
193 LIST_BEEP <D>
194 Beep on an ambiguous completion. More accurately, this forces
195 the completion widgets to return status 1 on an ambiguous com‐
196 pletion, which causes the shell to beep if the option BEEP is
197 also set; this may be modified if completion is called from a
198 user-defined widget.
199
200 LIST_PACKED
201 Try to make the completion list smaller (occupying less lines)
202 by printing the matches in columns with different widths.
203
204 LIST_ROWS_FIRST
205 Lay out the matches in completion lists sorted horizontally,
206 that is, the second match is to the right of the first one, not
207 under it as usual.
208
209 LIST_TYPES (-X) <D>
210 When listing files that are possible completions, show the type
211 of each file with a trailing identifying mark.
212
213 MENU_COMPLETE (-Y)
214 On an ambiguous completion, instead of listing possibilities or
215 beeping, insert the first match immediately. Then when comple‐
216 tion is requested again, remove the first match and insert the
217 second match, etc. When there are no more matches, go back to
218 the first one again. reverse-menu-complete may be used to loop
219 through the list in the other direction. This option overrides
220 AUTO_MENU.
221
222 REC_EXACT (-S)
223 In completion, recognize exact matches even if they are ambigu‐
224 ous.
225
226 Expansion and Globbing
227 BAD_PATTERN (+2) <C> <Z>
228 If a pattern for filename generation is badly formed, print an
229 error message. (If this option is unset, the pattern will be
230 left unchanged.)
231
232 BARE_GLOB_QUAL <Z>
233 In a glob pattern, treat a trailing set of parentheses as a
234 qualifier list, if it contains no `|', `(' or (if special) `~'
235 characters. See the section `Filename Generation'.
236
237 BRACE_CCL
238 Expand expressions in braces which would not otherwise undergo
239 brace expansion to a lexically ordered list of all the charac‐
240 ters. See the section `Brace Expansion'.
241
242 CASE_GLOB <D>
243 Make globbing (filename generation) sensitive to case. Note
244 that other uses of patterns are always sensitive to case. If
245 the option is unset, the presence of any character which is spe‐
246 cial to filename generation will cause case-insensitive match‐
247 ing. For example, cvs(/) can match the directory CVS owing to
248 the presence of the globbing flag (unless the option
249 BARE_GLOB_QUAL is unset).
250
251 CASE_MATCH <D>
252 Make regular expressions using the zsh/regex module (including
253 matches with =~) sensitive to case.
254
255 CSH_NULL_GLOB <C>
256 If a pattern for filename generation has no matches, delete the
257 pattern from the argument list; do not report an error unless
258 all the patterns in a command have no matches. Overrides
259 NOMATCH.
260
261 EQUALS <Z>
262 Perform = filename expansion. (See the section `Filename Expan‐
263 sion'.)
264
265 EXTENDED_GLOB
266 Treat the `#', `~' and `^' characters as part of patterns for
267 filename generation, etc. (An initial unquoted `~' always pro‐
268 duces named directory expansion.)
269
270 GLOB (+F, ksh: +f) <D>
271 Perform filename generation (globbing). (See the section `File‐
272 name Generation'.)
273
274 GLOB_ASSIGN <C>
275 If this option is set, filename generation (globbing) is per‐
276 formed on the right hand side of scalar parameter assignments of
277 the form `name=pattern (e.g. `foo=*'). If the result has more
278 than one word the parameter will become an array with those
279 words as arguments. This option is provided for backwards com‐
280 patibility only: globbing is always performed on the right hand
281 side of array assignments of the form `name=(value)' (e.g.
282 `foo=(*)') and this form is recommended for clarity; with this
283 option set, it is not possible to predict whether the result
284 will be an array or a scalar.
285
286 GLOB_DOTS (-4)
287 Do not require a leading `.' in a filename to be matched explic‐
288 itly.
289
290 GLOB_SUBST <C> <K> <S>
291 Treat any characters resulting from parameter expansion as being
292 eligible for file expansion and filename generation, and any
293 characters resulting from command substitution as being eligible
294 for filename generation. Braces (and commas in between) do not
295 become eligible for expansion.
296
297 HIST_SUBST_PATTERN
298 Substitutions using the :s and :& history modifiers are per‐
299 formed with pattern matching instead of string matching. This
300 occurs wherever history modifiers are valid, including glob
301 qualifiers and parameters. See the section Modifiers in zsh‐
302 exp(1).
303
304 IGNORE_BRACES (-I) <S>
305 Do not perform brace expansion.
306
307 KSH_GLOB <K>
308 In pattern matching, the interpretation of parentheses is
309 affected by a preceding `@', `*', `+', `?' or `!'. See the sec‐
310 tion `Filename Generation'.
311
312 MAGIC_EQUAL_SUBST
313 All unquoted arguments of the form `anything=expression' appear‐
314 ing after the command name have filename expansion (that is,
315 where expression has a leading `~' or `=') performed on expres‐
316 sion as if it were a parameter assignment. The argument is not
317 otherwise treated specially; it is passed to the command as a
318 single argument, and not used as an actual parameter assignment.
319 For example, in echo foo=~/bar:~/rod, both occurrences of ~
320 would be replaced. Note that this happens anyway with typeset
321 and similar statements.
322
323 This option respects the setting of the KSH_TYPESET option. In
324 other words, if both options are in effect, arguments looking
325 like assignments will not undergo word splitting.
326
327 MARK_DIRS (-8, ksh: -X)
328 Append a trailing `/' to all directory names resulting from
329 filename generation (globbing).
330
331 MULTIBYTE <C> <K> <Z>
332 Respect multibyte characters when found in strings. When this
333 option is set, strings are examined using the system library to
334 determine how many bytes form a character, depending on the cur‐
335 rent locale. This affects the way characters are counted in
336 pattern matching, parameter values and various delimiters.
337
338 The option is on by default if the shell was compiled with
339 MULTIBYTE_SUPPORT except in sh emulation; otherwise it is off by
340 default and has no effect if turned on. The mode is off in sh
341 emulation for compatibility but for interactive use may need to
342 be turned on if the terminal interprets multibyte characters.
343
344 If the option is off a single byte is always treated as a single
345 character. This setting is designed purely for examining
346 strings known to contain raw bytes or other values that may not
347 be characters in the current locale. It is not necessary to
348 unset the option merely because the character set for the cur‐
349 rent locale does not contain multibyte characters.
350
351 The option does not affect the shell's editor, which always
352 uses the locale to determine multibyte characters. This is
353 because the character set displayed by the terminal emulator is
354 independent of shell settings.
355
356 NOMATCH (+3) <C> <Z>
357 If a pattern for filename generation has no matches, print an
358 error, instead of leaving it unchanged in the argument list.
359 This also applies to file expansion of an initial `~' or `='.
360
361 NULL_GLOB (-G)
362 If a pattern for filename generation has no matches, delete the
363 pattern from the argument list instead of reporting an error.
364 Overrides NOMATCH.
365
366 NUMERIC_GLOB_SORT
367 If numeric filenames are matched by a filename generation pat‐
368 tern, sort the filenames numerically rather than lexicographi‐
369 cally.
370
371 RC_EXPAND_PARAM (-P)
372 Array expansions of the form `foo${xx}bar', where the parameter
373 xx is set to (a b c), are substituted with `fooabar foobbar
374 foocbar' instead of the default `fooa b cbar'. Note that an
375 empty array will therefore cause all arguments to be removed.
376
377 REMATCH_PCRE <Z>
378 If set, regular expression matching with the =~ operator will
379 use Perl-Compatible Regular Expressions from the PCRE library,
380 if available. If not set, regular expressions will use the
381 extended regexp syntax provided by the system libraries.
382
383 SH_GLOB <K> <S>
384 Disables the special meaning of `(', `|', `)' and '<' for glob‐
385 bing the result of parameter and command substitutions, and in
386 some other places where the shell accepts patterns. This option
387 is set by default if zsh is invoked as sh or ksh.
388
389 UNSET (+u, ksh: +u) <K> <S> <Z>
390 Treat unset parameters as if they were empty when substituting.
391 Otherwise they are treated as an error.
392
393 WARN_CREATE_GLOBAL
394 Print a warning message when a global parameter is created in a
395 function by an assignment. This often indicates that a parame‐
396 ter has not been declared local when it should have been.
397 Parameters explicitly declared global from within a function
398 using typeset -g do not cause a warning. Note that there is no
399 warning when a local parameter is assigned to in a nested func‐
400 tion, which may also indicate an error.
401
402 History
403 APPEND_HISTORY <D>
404 If this is set, zsh sessions will append their history list to
405 the history file, rather than replace it. Thus, multiple paral‐
406 lel zsh sessions will all have the new entries from their his‐
407 tory lists added to the history file, in the order that they
408 exit. The file will still be periodically re-written to trim it
409 when the number of lines grows 20% beyond the value specified by
410 $SAVEHIST (see also the HIST_SAVE_BY_COPY option).
411
412 BANG_HIST (+K) <C> <Z>
413 Perform textual history expansion, csh-style, treating the char‐
414 acter `!' specially.
415
416 EXTENDED_HISTORY <C>
417 Save each command's beginning timestamp (in seconds since the
418 epoch) and the duration (in seconds) to the history file. The
419 format of this prefixed data is:
420
421 `:<beginning time>:<elapsed seconds>:<command>'.
422
423 HIST_ALLOW_CLOBBER
424 Add `|' to output redirections in the history. This allows his‐
425 tory references to clobber files even when CLOBBER is unset.
426
427 HIST_BEEP <D>
428 Beep when an attempt is made to access a history entry which
429 isn't there.
430
431 HIST_EXPIRE_DUPS_FIRST
432 If the internal history needs to be trimmed to add the current
433 command line, setting this option will cause the oldest history
434 event that has a duplicate to be lost before losing a unique
435 event from the list. You should be sure to set the value of
436 HISTSIZE to a larger number than SAVEHIST in order to give you
437 some room for the duplicated events, otherwise this option will
438 behave just like HIST_IGNORE_ALL_DUPS once the history fills up
439 with unique events.
440
441 HIST_FCNTL_LOCK
442 When writing out the history file, by default zsh uses ad-hoc
443 file locking to avoid known problems with locking on some oper‐
444 ating systems. With this option locking is done by means of the
445 system's fcntl call, where this method is available. On recent
446 operating systems this may provide better performance, in par‐
447 ticular avoiding history corruption when files are stored on
448 NFS.
449
450 HIST_FIND_NO_DUPS
451 When searching for history entries in the line editor, do not
452 display duplicates of a line previously found, even if the
453 duplicates are not contiguous.
454
455 HIST_IGNORE_ALL_DUPS
456 If a new command line being added to the history list duplicates
457 an older one, the older command is removed from the list (even
458 if it is not the previous event).
459
460 HIST_IGNORE_DUPS (-h)
461 Do not enter command lines into the history list if they are
462 duplicates of the previous event.
463
464 HIST_IGNORE_SPACE (-g)
465 Remove command lines from the history list when the first char‐
466 acter on the line is a space, or when one of the expanded
467 aliases contains a leading space. Note that the command lingers
468 in the internal history until the next command is entered before
469 it vanishes, allowing you to briefly reuse or edit the line. If
470 you want to make it vanish right away without entering another
471 command, type a space and press return.
472
473 HIST_NO_FUNCTIONS
474 Remove function definitions from the history list. Note that
475 the function lingers in the internal history until the next com‐
476 mand is entered before it vanishes, allowing you to briefly re‐
477 use or edit the definition.
478
479 HIST_NO_STORE
480 Remove the history (fc -l) command from the history list when
481 invoked. Note that the command lingers in the internal history
482 until the next command is entered before it vanishes, allowing
483 you to briefly reuse or edit the line.
484
485 HIST_REDUCE_BLANKS
486 Remove superfluous blanks from each command line being added to
487 the history list.
488
489 HIST_SAVE_BY_COPY <D>
490 When the history file is re-written, we normally write out a
491 copy of the file named $HISTFILE.new and then rename it over the
492 old one. However, if this option is unset, we instead truncate
493 the old history file and write out the new version in-place. If
494 one of the history-appending options is enabled, this option
495 only has an effect when the enlarged history file needs to be
496 re-written to trim it down to size. Disable this only if you
497 have special needs, as doing so makes it possible to lose his‐
498 tory entries if zsh gets interrupted during the save.
499
500 When writing out a copy of the history file, zsh preserves the
501 old file's permissions and group information, but will refuse to
502 write out a new file if it would change the history file's
503 owner.
504
505 HIST_SAVE_NO_DUPS
506 When writing out the history file, older commands that duplicate
507 newer ones are omitted.
508
509 HIST_VERIFY
510 Whenever the user enters a line with history expansion, don't
511 execute the line directly; instead, perform history expansion
512 and reload the line into the editing buffer.
513
514 INC_APPEND_HISTORY
515 This options works like APPEND_HISTORY except that new history
516 lines are added to the $HISTFILE incrementally (as soon as they
517 are entered), rather than waiting until the shell exits. The
518 file will still be periodically re-written to trim it when the
519 number of lines grows 20% beyond the value specified by $SAVE‐
520 HIST (see also the HIST_SAVE_BY_COPY option).
521
522 SHARE_HISTORY <K>
523
524 This option both imports new commands from the history file, and
525 also causes your typed commands to be appended to the history
526 file (the latter is like specifying INC_APPEND_HISTORY). The
527 history lines are also output with timestamps ala EXTENDED_HIS‐
528 TORY (which makes it easier to find the spot where we left off
529 reading the file after it gets re-written).
530
531 By default, history movement commands visit the imported lines
532 as well as the local lines, but you can toggle this on and off
533 with the set-local-history zle binding. It is also possible to
534 create a zle widget that will make some commands ignore imported
535 commands, and some include them.
536
537 If you find that you want more control over when commands get
538 imported, you may wish to turn SHARE_HISTORY off,
539 INC_APPEND_HISTORY on, and then manually import commands when‐
540 ever you need them using `fc -RI'.
541
542 Initialisation
543 ALL_EXPORT (-a, ksh: -a)
544 All parameters subsequently defined are automatically exported.
545
546 GLOBAL_EXPORT (<Z>)
547 If this option is set, passing the -x flag to the builtins
548 declare, float, integer, readonly and typeset (but not local)
549 will also set the -g flag; hence parameters exported to the
550 environment will not be made local to the enclosing function,
551 unless they were already or the flag +g is given explicitly. If
552 the option is unset, exported parameters will be made local in
553 just the same way as any other parameter.
554
555 This option is set by default for backward compatibility; it is
556 not recommended that its behaviour be relied upon. Note that
557 the builtin export always sets both the -x and -g flags, and
558 hence its effect extends beyond the scope of the enclosing func‐
559 tion; this is the most portable way to achieve this behaviour.
560
561 GLOBAL_RCS (-d) <D>
562 If this option is unset, the startup files /etc/zprofile,
563 /etc/zshrc, /etc/zlogin and /etc/zlogout will not be run. It
564 can be disabled and re-enabled at any time, including inside
565 local startup files (.zshrc, etc.).
566
567 RCS (+f) <D>
568 After /etc/zshenv is sourced on startup, source the .zshenv,
569 /etc/zprofile, .zprofile, /etc/zshrc, .zshrc, /etc/zlogin, .zlo‐
570 gin, and .zlogout files, as described in the section `Files'.
571 If this option is unset, the /etc/zshenv file is still sourced,
572 but any of the others will not be; it can be set at any time to
573 prevent the remaining startup files after the currently execut‐
574 ing one from being sourced.
575
576 Input/Output
577 ALIASES <D>
578 Expand aliases.
579
580 CLOBBER (+C, ksh: +C) <D>
581 Allows `>' redirection to truncate existing files, and `>>' to
582 create files. Otherwise `>!' or `>|' must be used to truncate a
583 file, and `>>!' or `>>|' to create a file.
584
585 CORRECT (-0)
586 Try to correct the spelling of commands. Note that, when the
587 HASH_LIST_ALL option is not set or when some directories in the
588 path are not readable, this may falsely report spelling errors
589 the first time some commands are used.
590
591 The shell variable CORRECT_IGNORE may be set to a pattern to
592 match words that will never be offered as corrections.
593
594 CORRECT_ALL (-O)
595 Try to correct the spelling of all arguments in a line.
596
597 DVORAK Use the Dvorak keyboard instead of the standard qwerty keyboard
598 as a basis for examining spelling mistakes for the CORRECT and
599 CORRECT_ALL options and the spell-word editor command.
600
601 FLOW_CONTROL <D>
602 If this option is unset, output flow control via start/stop
603 characters (usually assigned to ^S/^Q) is disabled in the
604 shell's editor.
605
606 IGNORE_EOF (-7)
607 Do not exit on end-of-file. Require the use of exit or logout
608 instead. However, ten consecutive EOFs will cause the shell to
609 exit anyway, to avoid the shell hanging if its tty goes away.
610
611 Also, if this option is set and the Zsh Line Editor is used,
612 widgets implemented by shell functions can be bound to EOF (nor‐
613 mally Control-D) without printing the normal warning message.
614 This works only for normal widgets, not for completion widgets.
615
616 INTERACTIVE_COMMENTS (-k) <K> <S>
617 Allow comments even in interactive shells.
618
619 HASH_CMDS <D>
620 Note the location of each command the first time it is executed.
621 Subsequent invocations of the same command will use the saved
622 location, avoiding a path search. If this option is unset, no
623 path hashing is done at all. However, when CORRECT is set, com‐
624 mands whose names do not appear in the functions or aliases hash
625 tables are hashed in order to avoid reporting them as spelling
626 errors.
627
628 HASH_DIRS <D>
629 Whenever a command name is hashed, hash the directory containing
630 it, as well as all directories that occur earlier in the path.
631 Has no effect if neither HASH_CMDS nor CORRECT is set.
632
633 MAIL_WARNING (-U)
634 Print a warning message if a mail file has been accessed since
635 the shell last checked.
636
637 PATH_DIRS (-Q)
638 Perform a path search even on command names with slashes in
639 them. Thus if `/usr/local/bin' is in the user's path, and he or
640 she types `X11/xinit', the command `/usr/local/bin/X11/xinit'
641 will be executed (assuming it exists). Commands explicitly
642 beginning with `/', `./' or `../' are not subject to the path
643 search. This also applies to the `.' builtin.
644
645 Note that subdirectories of the current directory are always
646 searched for executables specified in this form. This takes
647 place before any search indicated by this option, and regardless
648 of whether `.' or the current directory appear in the command
649 search path.
650
651 PRINT_EIGHT_BIT
652 Print eight bit characters literally in completion lists, etc.
653 This option is not necessary if your system correctly returns
654 the printability of eight bit characters (see ctype(3)).
655
656 PRINT_EXIT_VALUE (-1)
657 Print the exit value of programs with non-zero exit status.
658
659 RC_QUOTES
660 Allow the character sequence `''' to signify a single quote
661 within singly quoted strings. Note this does not apply in
662 quoted strings using the format $'...', where a backslashed sin‐
663 gle quote can be used.
664
665 RM_STAR_SILENT (-H) <K> <S>
666 Do not query the user before executing `rm *' or `rm path/*'.
667
668 RM_STAR_WAIT
669 If querying the user before executing `rm *' or `rm path/*',
670 first wait ten seconds and ignore anything typed in that time.
671 This avoids the problem of reflexively answering `yes' to the
672 query when one didn't really mean it. The wait and query can
673 always be avoided by expanding the `*' in ZLE (with tab).
674
675 SHORT_LOOPS <C> <Z>
676 Allow the short forms of for, repeat, select, if, and function
677 constructs.
678
679 SUN_KEYBOARD_HACK (-L)
680 If a line ends with a backquote, and there are an odd number of
681 backquotes on the line, ignore the trailing backquote. This is
682 useful on some keyboards where the return key is too small, and
683 the backquote key lies annoyingly close to it.
684
685 Job Control
686 AUTO_CONTINUE
687 With this option set, stopped jobs that are removed from the job
688 table with the disown builtin command are automatically sent a
689 CONT signal to make them running.
690
691 AUTO_RESUME (-W)
692 Treat single word simple commands without redirection as candi‐
693 dates for resumption of an existing job.
694
695 BG_NICE (-6) <C> <Z>
696 Run all background jobs at a lower priority. This option is set
697 by default.
698
699 CHECK_JOBS <Z>
700 Report the status of background and suspended jobs before exit‐
701 ing a shell with job control; a second attempt to exit the shell
702 will succeed. NO_CHECK_JOBS is best used only in combination
703 with NO_HUP, else such jobs will be killed automatically.
704
705 The check is omitted if the commands run from the previous com‐
706 mand line included a `jobs' command, since it is assumed the
707 user is aware that there are background or suspended jobs. A
708 `jobs' command run from one of the hook functions defined in the
709 section SPECIAL FUNCTIONS in zshmisc(1) is not counted for this
710 purpose.
711
712 HUP <Z>
713 Send the HUP signal to running jobs when the shell exits.
714
715 LONG_LIST_JOBS (-R)
716 List jobs in the long format by default.
717
718 MONITOR (-m, ksh: -m)
719 Allow job control. Set by default in interactive shells.
720
721 NOTIFY (-5, ksh: -b) <Z>
722 Report the status of background jobs immediately, rather than
723 waiting until just before printing a prompt.
724
725 Prompting
726 PROMPT_BANG <K>
727 If set, `!' is treated specially in prompt expansion. See
728 EXPANSION OF PROMPT SEQUENCES in zshmisc(1).
729
730 PROMPT_CR (+V) <D>
731 Print a carriage return just before printing a prompt in the
732 line editor. This is on by default as multi-line editing is
733 only possible if the editor knows where the start of the line
734 appears.
735
736 PROMPT_SP <D>
737 Attempt to preserve a partial line (i.e. a line that did not end
738 with a newline) that would otherwise be covered up by the com‐
739 mand prompt due to the PROMPT_CR option. This works by out‐
740 putting some cursor-control characters, including a series of
741 spaces, that should make the terminal wrap to the next line when
742 a partial line is present (note that this is only successful if
743 your terminal has automatic margins, which is typical).
744
745 When a partial line is preserved, by default you will see an
746 inverse+bold character at the end of the partial line: a "%"
747 for a normal user or a "#" for root. If set, the shell parame‐
748 ter PROMPT_EOL_MARK can be used to customize how the end of par‐
749 tial lines are shown.
750
751 NOTE: if the PROMPT_CR option is not set, enabling this option
752 will have no effect. This option is on by default.
753
754 PROMPT_PERCENT <C> <Z>
755 If set, `%' is treated specially in prompt expansion. See
756 EXPANSION OF PROMPT SEQUENCES in zshmisc(1).
757
758 PROMPT_SUBST <K> <S>
759 If set, parameter expansion, command substitution and arithmetic
760 expansion are performed in prompts. Substitutions within
761 prompts do not affect the command status.
762
763 TRANSIENT_RPROMPT
764 Remove any right prompt from display when accepting a command
765 line. This may be useful with terminals with other cut/paste
766 methods.
767
768 Scripts and Functions
769 C_BASES
770 Output hexadecimal numbers in the standard C format, for example
771 `0xFF' instead of the usual `16#FF'. If the option OCTAL_ZEROES
772 is also set (it is not by default), octal numbers will be
773 treated similarly and hence appear as `077' instead of `8#77'.
774 This option has no effect on the choice of the output base, nor
775 on the output of bases other than hexadecimal and octal. Note
776 that these formats will be understood on input irrespective of
777 the setting of C_BASES.
778
779 C_PRECEDENCES
780 This alters the precedence of arithmetic operators to be more
781 like C and other programming languages; the section ARITHMETIC
782 EVALUATION in zshmisc(1) has an explicit list.
783
784 DEBUG_BEFORE_CMD
785 Run the DEBUG trap before each command; otherwise it is run
786 after each command. Setting this option mimics the behaviour of
787 ksh 93; with the option unset the behaviour is that of ksh 88.
788
789 ERR_EXIT (-e, ksh: -e)
790 If a command has a non-zero exit status, execute the ZERR trap,
791 if set, and exit. This is disabled while running initialization
792 scripts.
793
794 The behaviour is also disabled inside DEBUG traps. In this case
795 the option is handled specially: it is unset on entry to the
796 trap. If the option DEBUG_BEFORE_CMD is set, as it is by
797 default, and the option ERR_EXIT is found to have been set on
798 exit, then the command for which the DEBUG trap is being exe‐
799 cuted is skipped. The option is restored after the trap exits.
800
801 ERR_RETURN
802 If a command has a non-zero exit status, return immediately from
803 the enclosing function. The logic is identical to that for
804 ERR_EXIT, except that an implicit return statement is executed
805 instead of an exit. This will trigger an exit at the outermost
806 level of a non-interactive script.
807
808 EVAL_LINENO <Z>
809 If set, line numbers of expressions evaluated using the builtin
810 eval are tracked separately of the enclosing environment. This
811 applies both to the parameter LINENO and the line number output
812 by the prompt escape %i. If the option is set, the prompt
813 escape %N will output the string `(eval)' instead of the script
814 or function name as an indication. (The two prompt escapes are
815 typically used in the parameter PS4 to be output when the option
816 XTRACE is set.) If EVAL_LINENO is unset, the line number of the
817 surrounding script or function is retained during the evalua‐
818 tion.
819
820 EXEC (+n, ksh: +n) <D>
821 Do execute commands. Without this option, commands are read and
822 checked for syntax errors, but not executed. This option cannot
823 be turned off in an interactive shell, except when `-n' is sup‐
824 plied to the shell at startup.
825
826 FUNCTION_ARGZERO <C> <Z>
827 When executing a shell function or sourcing a script, set $0
828 temporarily to the name of the function/script.
829
830 LOCAL_OPTIONS <K>
831 If this option is set at the point of return from a shell func‐
832 tion, most options (including this one) which were in force upon
833 entry to the function are restored; options that are not
834 restored are PRIVILEGED and RESTRICTED. Otherwise, only this
835 option and the XTRACE and PRINT_EXIT_VALUE options are restored.
836 Hence if this is explicitly unset by a shell function the other
837 options in force at the point of return will remain so. A shell
838 function can also guarantee itself a known shell configuration
839 with a formulation like `emulate -L zsh'; the -L activates
840 LOCAL_OPTIONS.
841
842 LOCAL_TRAPS <K>
843 If this option is set when a signal trap is set inside a func‐
844 tion, then the previous status of the trap for that signal will
845 be restored when the function exits. Note that this option must
846 be set prior to altering the trap behaviour in a function;
847 unlike LOCAL_OPTIONS, the value on exit from the function is
848 irrelevant. However, it does not need to be set before any
849 global trap for that to be correctly restored by a function.
850 For example,
851
852 unsetopt localtraps
853 trap - INT
854 fn() { setopt localtraps; trap '' INT; sleep 3; }
855
856 will restore normally handling of SIGINT after the function
857 exits.
858
859 MULTI_FUNC_DEF <Z>
860 Allow definitions of multiple functions at once in the form `fn1
861 fn2...()'; if the option is not set, this causes a parse error.
862 Definition of multiple functions with the function keyword is
863 always allowed. Multiple function definitions are not often
864 used and can cause obscure errors.
865
866 MULTIOS <Z>
867 Perform implicit tees or cats when multiple redirections are
868 attempted (see the section `Redirection').
869
870 OCTAL_ZEROES <S>
871 Interpret any integer constant beginning with a 0 as octal, per
872 IEEE Std 1003.2-1992 (ISO 9945-2:1993). This is not enabled by
873 default as it causes problems with parsing of, for example, date
874 and time strings with leading zeroes.
875
876 Sequences of digits indicating a numeric base such as the `08'
877 component in `08#77' are always interpreted as decimal, regard‐
878 less of leading zeroes.
879
880 TYPESET_SILENT
881 If this is unset, executing any of the `typeset' family of com‐
882 mands with no options and a list of parameters that have no val‐
883 ues to be assigned but already exist will display the value of
884 the parameter. If the option is set, they will only be shown
885 when parameters are selected with the `-m' option. The option
886 `-p' is available whether or not the option is set.
887
888 VERBOSE (-v, ksh: -v)
889 Print shell input lines as they are read.
890
891 XTRACE (-x, ksh: -x)
892 Print commands and their arguments as they are executed.
893
894 Shell Emulation
895 BASH_REMATCH
896 When set, matches performed with the =~ operator will set the
897 BASH_REMATCH array variable, instead of the default MATCH and
898 match variables. The first element of the BASH_REMATCH array
899 will contain the entire matched text and subsequent elements
900 will contain extracted substrings. This option makes more sense
901 when KSH_ARRAYS is also set, so that the entire matched portion
902 is stored at index 0 and the first substring is at index 1.
903 Without this option, the MATCH variable contains the entire
904 matched text and the match array variable contains substrings.
905
906 BSD_ECHO <S>
907 Make the echo builtin compatible with the BSD echo(1) command.
908 This disables backslashed escape sequences in echo strings
909 unless the -e option is specified.
910
911 CSH_JUNKIE_HISTORY <C>
912 A history reference without an event specifier will always refer
913 to the previous command. Without this option, such a history
914 reference refers to the same event as the previous history ref‐
915 erence, defaulting to the previous command.
916
917 CSH_JUNKIE_LOOPS <C>
918 Allow loop bodies to take the form `list; end' instead of `do
919 list; done'.
920
921 CSH_JUNKIE_QUOTES <C>
922 Changes the rules for single- and double-quoted text to match
923 that of csh. These require that embedded newlines be preceded
924 by a backslash; unescaped newlines will cause an error message.
925 In double-quoted strings, it is made impossible to escape `$',
926 ``' or `"' (and `\' itself no longer needs escaping). Command
927 substitutions are only expanded once, and cannot be nested.
928
929 CSH_NULLCMD <C>
930 Do not use the values of NULLCMD and READNULLCMD when running
931 redirections with no command. This make such redirections fail
932 (see the section `Redirection').
933
934 KSH_ARRAYS <K> <S>
935 Emulate ksh array handling as closely as possible. If this
936 option is set, array elements are numbered from zero, an array
937 parameter without subscript refers to the first element instead
938 of the whole array, and braces are required to delimit a sub‐
939 script (`${path[2]}' rather than just `$path[2]').
940
941 KSH_AUTOLOAD <K> <S>
942 Emulate ksh function autoloading. This means that when a func‐
943 tion is autoloaded, the corresponding file is merely executed,
944 and must define the function itself. (By default, the function
945 is defined to the contents of the file. However, the most com‐
946 mon ksh-style case - of the file containing only a simple defi‐
947 nition of the function - is always handled in the ksh-compatible
948 manner.)
949
950 KSH_OPTION_PRINT <K>
951 Alters the way options settings are printed: instead of separate
952 lists of set and unset options, all options are shown, marked
953 `on' if they are in the non-default state, `off' otherwise.
954
955 KSH_TYPESET <K>
956 Alters the way arguments to the typeset family of commands,
957 including declare, export, float, integer, local and readonly,
958 are processed. Without this option, zsh will perform normal
959 word splitting after command and parameter expansion in argu‐
960 ments of an assignment; with it, word splitting does not take
961 place in those cases.
962
963 KSH_ZERO_SUBSCRIPT
964 Treat use of a subscript of value zero in array or string
965 expressions as a reference to the first element, i.e. the ele‐
966 ment that usually has the subscript 1. Ignored if KSH_ARRAYS is
967 also set.
968
969 If neither this option nor KSH_ARRAYS is set, accesses to an
970 element of an array or string with subscript zero return an
971 empty element or string, while attempts to set element zero of
972 an array or string are treated as an error. However, attempts
973 to set an otherwise valid subscript range that includes zero
974 will succeed. For example, if KSH_ZERO_SUBSCRIPT is not set,
975
976 array[0]=(element)
977
978 is an error, while
979
980 array[0,1]=(element)
981
982 is not and will replace the first element of the array.
983
984 This option is for compatibility with older versions of the
985 shell and is not recommended in new code.
986
987 POSIX_ALIASES <K> <S>
988 When this option is set, reserved words are not candidates for
989 alias expansion: it is still possible to declare any of them as
990 an alias, but the alias will never be expanded. Reserved words
991 are described in the section RESERVED WORDS in zshmisc(1).
992
993 Alias expansion takes place while text is being read; hence when
994 this option is set it does not take effect until the end of any
995 function or other piece of shell code parsed as one unit. Note
996 this may cause differences from other shells even when the
997 option is in effect. For example, when running a command with
998 `zsh -c', or even `zsh -o posixaliases -c', the entire command
999 argument is parsed as one unit, so aliases defined within the
1000 argument are not available even in later lines. If in doubt,
1001 avoid use of aliases in non-interactive code.
1002
1003 POSIX_BUILTINS <K> <S>
1004 When this option is set the command builtin can be used to exe‐
1005 cute shell builtin commands. Parameter assignments specified
1006 before shell functions and special builtins are kept after the
1007 command completes unless the special builtin is prefixed with
1008 the command builtin. Special builtins are ., :, break, con‐
1009 tinue, declare, eval, exit, export, integer, local, readonly,
1010 return, set, shift, source, times, trap and unset.
1011
1012 POSIX_IDENTIFIERS <K> <S>
1013 When this option is set, only the ASCII characters a to z, A to
1014 Z, 0 to 9 and _ may be used in identifiers (names of shell
1015 parameters and modules).
1016
1017 When the option is unset and multibyte character support is
1018 enabled (i.e. it is compiled in and the option MULTIBYTE is
1019 set), then additionally any alphanumeric characters in the local
1020 character set may be used in identifiers. Note that scripts and
1021 functions written with this feature are not portable, and also
1022 that both options must be set before the script or function is
1023 parsed; setting them during execution is not sufficient as the
1024 syntax variable=value has already been parsed as a command
1025 rather than an assignment.
1026
1027 If multibyte character support is not compiled into the shell
1028 this option is ignored; all octets with the top bit set may be
1029 used in identifiers. This is non-standard but is the tradi‐
1030 tional zsh behaviour.
1031
1032 SH_FILE_EXPANSION <K> <S>
1033 Perform filename expansion (e.g., ~ expansion) before parameter
1034 expansion, command substitution, arithmetic expansion and brace
1035 expansion. If this option is unset, it is performed after brace
1036 expansion, so things like `~$USERNAME' and `~{pfalstad,rc}' will
1037 work.
1038
1039 SH_NULLCMD <K> <S>
1040 Do not use the values of NULLCMD and READNULLCMD when doing
1041 redirections, use `:' instead (see the section `Redirection').
1042
1043 SH_OPTION_LETTERS <K> <S>
1044 If this option is set the shell tries to interpret single letter
1045 options (which are used with set and setopt) like ksh does.
1046 This also affects the value of the - special parameter.
1047
1048 SH_WORD_SPLIT (-y) <K> <S>
1049 Causes field splitting to be performed on unquoted parameter
1050 expansions. Note that this option has nothing to do with word
1051 splitting. (See the section `Parameter Expansion'.)
1052
1053 TRAPS_ASYNC
1054 While waiting for a program to exit, handle signals and run
1055 traps immediately. Otherwise the trap is run after a child
1056 process has exited. Note this does not affect the point at
1057 which traps are run for any case other than when the shell is
1058 waiting for a child process.
1059
1060 Shell State
1061 INTERACTIVE (-i, ksh: -i)
1062 This is an interactive shell. This option is set upon initiali‐
1063 sation if the standard input is a tty and commands are being
1064 read from standard input. (See the discussion of SHIN_STDIN.)
1065 This heuristic may be overridden by specifying a state for this
1066 option on the command line. The value of this option can only
1067 be changed via flags supplied at invocation of the shell. It
1068 cannot be changed once zsh is running.
1069
1070 LOGIN (-l, ksh: -l)
1071 This is a login shell. If this option is not explicitly set,
1072 the shell is a login shell if the first character of the argv[0]
1073 passed to the shell is a `-'.
1074
1075 PRIVILEGED (-p, ksh: -p)
1076 Turn on privileged mode. This is enabled automatically on
1077 startup if the effective user (group) ID is not equal to the
1078 real user (group) ID. Turning this option off causes the effec‐
1079 tive user and group IDs to be set to the real user and group
1080 IDs. This option disables sourcing user startup files. If zsh
1081 is invoked as `sh' or `ksh' with this option set, /etc/suid_pro‐
1082 file is sourced (after /etc/profile on interactive shells).
1083 Sourcing ~/.profile is disabled and the contents of the ENV
1084 variable is ignored. This option cannot be changed using the -m
1085 option of setopt and unsetopt, and changing it inside a function
1086 always changes it globally regardless of the LOCAL_OPTIONS
1087 option.
1088
1089 RESTRICTED (-r)
1090 Enables restricted mode. This option cannot be changed using
1091 unsetopt, and setting it inside a function always changes it
1092 globally regardless of the LOCAL_OPTIONS option. See the sec‐
1093 tion `Restricted Shell'.
1094
1095 SHIN_STDIN (-s, ksh: -s)
1096 Commands are being read from the standard input. Commands are
1097 read from standard input if no command is specified with -c and
1098 no file of commands is specified. If SHIN_STDIN is set explic‐
1099 itly on the command line, any argument that would otherwise have
1100 been taken as a file to run will instead be treated as a normal
1101 positional parameter. Note that setting or unsetting this
1102 option on the command line does not necessarily affect the state
1103 the option will have while the shell is running - that is purely
1104 an indicator of whether on not commands are actually being read
1105 from standard input. The value of this option can only be
1106 changed via flags supplied at invocation of the shell. It can‐
1107 not be changed once zsh is running.
1108
1109 SINGLE_COMMAND (-t, ksh: -t)
1110 If the shell is reading from standard input, it exits after a
1111 single command has been executed. This also makes the shell
1112 non-interactive, unless the INTERACTIVE option is explicitly set
1113 on the command line. The value of this option can only be
1114 changed via flags supplied at invocation of the shell. It can‐
1115 not be changed once zsh is running.
1116
1117 Zle
1118 BEEP (+B) <D>
1119 Beep on error in ZLE.
1120
1121 COMBINING_CHARS
1122 Assume that the terminal displays combining characters cor‐
1123 rectly. Specifically, if a base alphanumeric character is fol‐
1124 lowed by one or more zero-width punctuation characters, assume
1125 that the zero-width characters will be displayed as modifica‐
1126 tions to the base character within the same width. Not all ter‐
1127 minals handle this. If this option is not set, zero-width char‐
1128 acters are displayed separately with special mark-up.
1129
1130 If this option is set, the pattern test [[:WORD:]] matches a
1131 zero-width punctuation character on the assumption that it will
1132 be used as part of a word in combination with a word character.
1133 Otherwise the base shell does not handle combining characters
1134 specially.
1135
1136 EMACS If ZLE is loaded, turning on this option has the equivalent
1137 effect of `bindkey -e'. In addition, the VI option is unset.
1138 Turning it off has no effect. The option setting is not guaran‐
1139 teed to reflect the current keymap. This option is provided for
1140 compatibility; bindkey is the recommended interface.
1141
1142 OVERSTRIKE
1143 Start up the line editor in overstrike mode.
1144
1145 SINGLE_LINE_ZLE (-M) <K>
1146 Use single-line command line editing instead of multi-line.
1147
1148 Note that although this is on by default in ksh emulation it
1149 only provides superficial compatibility with the ksh line editor
1150 and reduces the effectiveness of the zsh line editor. As it has
1151 no effect on shell syntax, many users may wish to disable this
1152 option when using ksh emulation interactively.
1153
1154 VI If ZLE is loaded, turning on this option has the equivalent
1155 effect of `bindkey -v'. In addition, the EMACS option is unset.
1156 Turning it off has no effect. The option setting is not guaran‐
1157 teed to reflect the current keymap. This option is provided for
1158 compatibility; bindkey is the recommended interface.
1159
1160 ZLE (-Z)
1161 Use the zsh line editor. Set by default in interactive shells
1162 connected to a terminal.
1163
1165 Some options have alternative names. These aliases are never used for
1166 output, but can be used just like normal option names when specifying
1167 options to the shell.
1168
1169 BRACE_EXPAND
1170 NO_IGNORE_BRACES (ksh and bash compatibility)
1171
1172 DOT_GLOB
1173 GLOB_DOTS (bash compatibility)
1174
1175 HASH_ALL
1176 HASH_CMDS (bash compatibility)
1177
1178 HIST_APPEND
1179 APPEND_HISTORY (bash compatibility)
1180
1181 HIST_EXPAND
1182 BANG_HIST (bash compatibility)
1183
1184 LOG NO_HIST_NO_FUNCTIONS (ksh compatibility)
1185
1186 MAIL_WARN
1187 MAIL_WARNING (bash compatibility)
1188
1189 ONE_CMD
1190 SINGLE_COMMAND (bash compatibility)
1191
1192 PHYSICAL
1193 CHASE_LINKS (ksh and bash compatibility)
1194
1195 PROMPT_VARS
1196 PROMPT_SUBST (bash compatibility)
1197
1198 STDIN SHIN_STDIN (ksh compatibility)
1199
1200 TRACK_ALL
1201 HASH_CMDS (ksh compatibility)
1202
1204 Default set
1205 -0 CORRECT
1206 -1 PRINT_EXIT_VALUE
1207 -2 NO_BAD_PATTERN
1208 -3 NO_NOMATCH
1209 -4 GLOB_DOTS
1210 -5 NOTIFY
1211 -6 BG_NICE
1212 -7 IGNORE_EOF
1213 -8 MARK_DIRS
1214 -9 AUTO_LIST
1215 -B NO_BEEP
1216 -C NO_CLOBBER
1217 -D PUSHD_TO_HOME
1218 -E PUSHD_SILENT
1219 -F NO_GLOB
1220 -G NULL_GLOB
1221 -H RM_STAR_SILENT
1222 -I IGNORE_BRACES
1223 -J AUTO_CD
1224 -K NO_BANG_HIST
1225 -L SUN_KEYBOARD_HACK
1226 -M SINGLE_LINE_ZLE
1227 -N AUTO_PUSHD
1228 -O CORRECT_ALL
1229 -P RC_EXPAND_PARAM
1230 -Q PATH_DIRS
1231 -R LONG_LIST_JOBS
1232 -S REC_EXACT
1233 -T CDABLE_VARS
1234 -U MAIL_WARNING
1235 -V NO_PROMPT_CR
1236 -W AUTO_RESUME
1237 -X LIST_TYPES
1238 -Y MENU_COMPLETE
1239 -Z ZLE
1240 -a ALL_EXPORT
1241 -e ERR_EXIT
1242 -f NO_RCS
1243 -g HIST_IGNORE_SPACE
1244 -h HIST_IGNORE_DUPS
1245 -i INTERACTIVE
1246 -k INTERACTIVE_COMMENTS
1247 -l LOGIN
1248 -m MONITOR
1249 -n NO_EXEC
1250 -p PRIVILEGED
1251 -r RESTRICTED
1252 -s SHIN_STDIN
1253 -t SINGLE_COMMAND
1254 -u NO_UNSET
1255 -v VERBOSE
1256 -w CHASE_LINKS
1257 -x XTRACE
1258 -y SH_WORD_SPLIT
1259
1260 sh/ksh emulation set
1261 -C NO_CLOBBER
1262 -T TRAPS_ASYNC
1263 -X MARK_DIRS
1264 -a ALL_EXPORT
1265 -b NOTIFY
1266 -e ERR_EXIT
1267 -f NO_GLOB
1268 -i INTERACTIVE
1269 -l LOGIN
1270 -m MONITOR
1271 -n NO_EXEC
1272 -p PRIVILEGED
1273 -r RESTRICTED
1274 -s SHIN_STDIN
1275 -t SINGLE_COMMAND
1276 -u NO_UNSET
1277 -v VERBOSE
1278 -x XTRACE
1279
1280 Also note
1281 -A Used by set for setting arrays
1282 -b Used on the command line to specify end of option processing
1283 -c Used on the command line to specify a single command
1284 -m Used by setopt for pattern-matching option setting
1285 -o Used in all places to allow use of long option names
1286 -s Used by set to sort positional parameters
1287
1288
1289
1290zsh 4.3.10 June 1, 2009 ZSHOPTIONS(1)