The directory stack has normally unlimited size; if you want to restrict its size, set this variable to the value you want; you may also want to avoid duplicates in your stack, see OPTION_PUSHD_IGNORE_DUPS for details.
Here is an example of how DIRSTACKSIZE is used by ZSH:
% setopt AUTO_PUSHD # We want directories to be pushed automatically onto the stack (in this example)
% dirs -v # Displays contents of the directory stack; only the current direcory is in there right now.
0 ~
% for i in {1..2}; do # Let's change the directory a few times (for demonstration purposes)
cd /tmp
cd ~
done
% dirs -v
0 ~
1 /tmp
2 ~
3 /tmp
4 ~
% DIRSTACKSIZE=3
% dirs -v # No effect yet; you must issue a CD command to update the stack
0 ~
1 /tmp
2 ~
3 /tmp
4 ~
% cd /tmp
% dirs -v # Now it's in effect; the stacksize is 3, everything beyond got truncated
0 /tmp
1 ~
2 /tmp
DIRSTACKSIZE=10If this option is enabled, cd can be omitted almost always changing
directories; the only case where it is still required is if the directory
name happens to be equal to a command name. This option is very
convenient to quickly change directories, for instance
going one directory up becomes just .. instead of cd ...
% mkdir directory % directory zsh: command not found: directory % setopt AUTO_CD % directory # Now equivalent to 'cd directory' % mkdir dir # We create a directory that has the name of a command % dir # This is not equivalent to 'cd dir' because command 'dir' exists! dir directory
setopt AUTO_CDsetopt NO_AUTO_CDIf enabled, any cd command pushes the new directory onto the
directory stack automatically; this comes in handy if you want
to navigate between several directories without having to hassle
with the stack by yourself.
The see the contents of the stack, use the dirs -v command.
The stack itself is by default unlimited in size; it can, however,
be restricted by the DIRSTACK parameter. This
is often useful when AUTO_PUSHD is used. In case you don’t want
duplicate directories, set the PUSHD_IGNORE_DUPS option.
% dirs -v # Displays contents of directory stack 0 ~ % cd /tmp % dirs -v 0 /tmp % setopt AUTO_PUSHD % cd ~ % dirs -v 0 ~ 1 /tmp
setopt AUTO_PUSHDsetopt NO_AUTO_PUSHDIf set, any argument given to a cd command (or an implied cd if the
#OPTION_AUTO_CD option is set) that is neither a directory nor starts with a
slash will be expanded as if it were preceded by a ”~”. That is, you
can assign directory names to a variable and then cd into that directory
by passing the variable name as the argument:
% dir=/tmp/ # Assign directory name to a variable % cd dir # Note: We really mean "dir" here, not $dir! cd: no such file or directory: dir % setopt CDABLE_VARS # Now activate this option % cd dir # Now it works - we will switch to /tmp now, displayed as ~dir. ~dir % pwd /tmp
This feature is very helpful if there are directories that you need to
cd into frequently, such as folders containing projects you’re working on.
setopt CDABLE_VARSunsetopt CDABLE_VARSThis option resolves directories to its physical directory if .. is encountered anyhwere in the path
(or if only cd .. is used). This means that the working directory is fully resolved once .. is encountered.
This option is similar to #OPTION_CHASE_LINKS. But as the name suggests, CHASE_LINKS is an option
used to resolve symbolic links to the physical directory whereas this option works on standard
directories as well.
% unsetopt CHASE_DOTS % mkdir /tmp/example/ % ln -s /home/ch /tmp/example/link % cd /tmp/example/link % cd .. % pwd /tmp/example % setopt CHASE_DOTS % cd /tmp/example/link # Changes to /home/ch, but that is not yet resolved as no .. has been found % cd .. % pwd /home
unsetopt CHASE_DOTSunsetopt CDABLE_DOTSIf this option is set, if you pass a symlink to cd (or even a symlink as a part
of the path you pass), each symlink will be resolved to the actual folder.
% ls -ald *(@) # Show all symlinks in the current folder lrwxrwxrwx 1 ch ch 24 Jun 22 19:56 homedir -> /home/ch % unsetopt CHASE_LINKS % cd homedir % pwd homedir % cd # assume that this command brings me back to the previously active directory (cd -1) % setopt CHASE_LINKS % cd homedir % pwd /home/ch
Note: You can also achieve this behavior by passing the -P option to cd.
unsetopt CHASE_LINKSunsetopt CDABLE_VARSChanges the behavior of the cd, chdir, pushd commands for increased POSIX standard compliance.
If POSIX_CD is not set, the behavior of the cd command is described in the manual under zsh: 17 Shell Builtin
Commands.
If POSIX_CD is set, the behavior is changed in several ways:
cdwill now first test if any directory in thecdpath/CDPATHvariable contain the directory and if so, will change to that directory. Any directory under the current working directory is ignored - i.e., the directories listed incdpathhave a higher priority.cdwill no longer take arguments of the form{+|-}n, i.e., navigating the directory stack is no longer possible. (See related options such as #PUSHD_MINUS.)
% unsetopt POSIX_CD % mkdir /tmp/foo % mkdir /tmp/foo/bar % mkdir /tmp/bar % cdpath=(/tmp) % cd /tmp/foo % cd bar % pwd /tmp/foo/bar % cd /tmp/foo % setopt POSIX_CD % cd bar % pwd /tmp/bar
unsetopt POSIX_CDunsetopt POSIX_CDIf set, this option prevents any directory to be at two different positions in the stack; that is, every entry is unique. This option is especially useful if AUTO_PUSHD is set.
The following example demonstrates that duplicates are prevented:
% dirs -v 0 ~ % setopt PUSHD_IGNORE_DUPS % cd /tmp % dirs -v 0 /tmp 1 ~ % cd ~ % dirs -v # Here, the existing entry for ~ was removed and a new entry was pushed onto the stack 0 ~ 1 /tmp
setopt PUSHD_IGNORE_DUPSsetopt NO_PUSHD_IGNORE_DUPSThe cd and popd builtins can use the directory stack by the +/-
arguments. For instance, cd +1 switches to the directory represented
by the second element on the directory stack (as counting starts from
- and
cd -1does the same but starts counting upwards from the bottom
of the stack. (So cd -1 is the second last element.)
(Note: The content of the directory stack can be displayed with the dirs
builtin; use dirs -v if you want to see explicitly the position of
each element.)
The meaning of + and - in this context can be reversed by activating
this option:
% pushd /tmp /tmp ~ % pushd /bin /bin /tmp ~ % pushd /boot /boot /bin /tmp ~ % setopt PUSHD_MINUS % cd -1 /bin
setopt PUSHD_MINUSsetopt NO_PUSHD_MINUSIf unset (as is the default), ZSH will print the content of the
directory stack every time pushd or popd is used; with this option
enabled, any output will be suppressed.
% cd /bin % pushd ~ /bin % setopt PUSHD_SILENT % cd /tmp % pushd # Doesn't output anything anymore % dirs -v 0 /bin 1 /tmp
setopt PUSHD_SILENTsetopt NO_PUSHD_SILENTIf enabled, executing pushd without any parameters is the same as
executing pushd $HOME; this is also the case (even with this option
disabled) if the directory stack contains only one entry:
% cd /tmp % dirs /tmp % setopt NO_PUSHD_TO_HOME % pushd ~ /tmp % pwd /home/ch
If there is more than one entry on the stack and this option is unset,
then calling pushd will simply swap the first two entries on the
stack:
% pushd /tmp /tmp ~ % pushd /bin /bin /tmp ~ % pwd /bin % pushd /tmp /bin ~ % pwd /tmp
This behavior changes when this option is enabled:
% setopt PUSHD_TO_HOME % pushd /tmp /tmp ~ % pushd /bin /bin /tmp ~ % pushd ~ /bin /tmp ~
Note: If you don’t want the stack to contain duplicates as in the example above, use the PUSHD_IGNORE_DUPS option.
cf. Section 16.2.2 http://zsh.sourceforge.net/Doc/Release/Options.html#Options
Check userguide 6.2.2
Check 6.2.4 in the userguide.
Show menu completion by default if completion results are ambiguous
(otherwise you may have to press some keys, such as ^D);
this option does not select an entry on displaying the menu;
see option MENU_COMPLETE for that.
setopt AUTO_LISTsetopt AUTO_LISTCheck userguide 6.2.1
Check 6.2.4 of the user guide.
Check 6.2.4 of the user guide.
Check 6.2.4 of the user guide. This tells in the last sentence what it does NOT do.
Check userguide 6.2.1
If this option is enabled, aliases will not have the same completion as the command they are referring to as they are not internally substituted when completion is attempted; hence, aliases look like distinct commands to the completion.
setopt NO_COMPLETE_ALIASESIf enabled, completion can be called from within a word; the completion will then try and take both everything before and everything after the cursor into account: The position of the cursor determines where the completion is attempted.
% setopt NO_COMPLETE_IN_WORD # Disable this option first; default behavior % ls te* terr test1 % vi te<CURSOR:TAB>1 # Offers terr and test1 as completion % setopt COMPLETE_IN_WORD % vi te<CURSOR:TAB>1 # Completes to test1, as terr has no "1" at the end
setopt COMPLETE_IN_WORDsetopt NO_COMPLETE_IN_WORDIf this option is set, expanding a (glob) pattern will not insert all the matches but instead generates a list that can be cycled through like MENU_COMPLETE.
A * is added to the end of the word or at the position of the cursor,
if COMPLETE_IN_WORD is set; furthermore, as pattern
matching is used, this option also affects any completion for options,
user names etc.
Note: If pattern matching is employed, you cannot use matching control
to include constraints such as case-insensitivity or anchored matching.
However, this limitation only applies when the current word contains
a pattern; simply turning on the GLOB_COMPLETE option does not have
this effect.
% setopt NO_GLOB_COMPLETE # Disable this option first; default behavior % ls example* example1 example2 % cat example<TAB> # becomes cat example1 example2 % setopt GLOB_COMPLETE % cat example<TAB> # asks for completion: Only example1 or example2 is selected.
setopt NO_GLOB_COMPLETEThis option is required for completion.
To understand why, consider what happens when you want to execute a command: first, ZSH determines the exact path of the command by searching all directories
listed in the PATH variable (with directories listed in the order of priority, i.e., from highest
priority to lowest priority). To speed up consecutive searches, ZSH fills a hash-table with key-value
pairs for every directory listed in PATH that it has previously searched, where the key is the command and the value is the path of the first occurrence of that
command (i.e., only the very first occurrence in a folder in PATH). That is, when you execute the
next command, ZSH first checks if the command is already known by searching the hash-table and only
restarts scanning all directories if it has not yet been added.
ZSH doesn‘t need to search all folders but only until the first match for the command has been found. As a consequence, not
all commands are added to the hash table until all directories have been scanned. To enforce
searching all directories immediately, and not just until the first match, HASH_LIST_ALL can be set, even though the first scan is a bit slower since more
directories are fully scanned.
Note that, if HASH_LIST_ALL is not activated, then command completion is not available - as there is no guarantee
that all directories have been scanned, no guarantee exists that all commands are available for completion.
Note: This hash-table can be printed using the hash built-in command (and regenerated using the rehash command).
% hash # output reduced to only the last few lines zless=/usr/bin/zless zmore=/usr/bin/zmore znew=/usr/bin/znew zsh=/usr/bin/zsh zsh5=/usr/bin/zsh5 zstd=/usr/bin/zstd zstdcat=/usr/bin/zstdcat zstdgrep=/usr/bin/zstdgrep zstdless=/usr/bin/zstdless zstdmt=/usr/bin/zstdmt
(See also A User’s Guide to the Z-Shell for some more information.)
setopt HASH_LIST_ALLsetopt HASH_LIST_ALLCheck userguide 6.2.1
Check userguide 6.2.1
If set, this option reduces the size of the completion menu by making its columnwidth dynamic; that is, the width of columns will be determined by the content of the columns and each two columns might have different widths.
setopt LIST_PACKEDsetopt NO_LIST_PACKEDCheck userguide 6.2.5
Check 5.9.6 of the user guide and 6.2.5.
On an ambiguous completion, do not beep and show a menu with matches; the
first match is inserted immediately. If completion is requested again,
cycle through matches, and remove any changes made by a prior match. When
there are no more matches, go back to the first one.
reverse-menu-complete may be used to loop through the list in the other
direction. This option overrides AUTO_MENU.
% setopt MENU_COMPLETE % ls te* terr test1 % vi te<TAB> # selects 'terr' immediately
setopt NO_MENU_COMPLETEsetopt NO_MENU_COMPLETECheck userguide 6.2.1
This option does not seem to have any effect if
zstyle ':completion:*' accept-exact false
was set explicitly before.
Check 5.9.6 of the user guide.
Check userguide 5.8; if set, “ls =ls” will be equivalent to “ls `which ls`”
Check 5.9.4 in the user guide.
If disabled, globbing (filename generation) will be completely disabled; i.e., usingprint file* actually prints file* instead of all files
starting with the prefix file.
setopt GLOBsetopt GLOBIf activated, files with a leading ‘.’ are also matched by globbing,
except for .. (parent directory) and . (current directory).
This also means that the ‘.’ does not need to be explicitly specified to
enable completion.
% setopt NO_GLOB_DOTS # Disable this option first; default behavior % touch .example % ls *example zsh: no matches found: *example % vi example<TAB> # Does not complete to .example % setopt GLOB_DOTS % ls *example .example % vi example<TAB> # Completes to .example
setopt GLOB_DOTSsetopt NO_GLOB_DOTSIf a parameter (variable) gets expanded, any character resulting from this operation is being treated as eligible for file expansion and filename generation.
Note: Braces (and contained commas) do not become eligible for expansion.
% setopt NO_GLOB_SUBST % export TEST="*" % ls * testfile1 testfile2 % ls $TEST<TAB> # Becomes ls \* % setopt GLOB_SUBST % ls $TEST<TAB> # Becomes ls testfile1 testfile2
setopt NO_GLOB_SUBSTCheck userguide 5.8
If enabled, this option prints an error message if a filename generation pattern does
not match anything. This also applies to file expansion of an initial
'~' or '’=. However, if disabled, any pattern that does not
match will be left unchanged, i.e., it will be passed as an argument to
the command:
% setopt NOMATCH # Default in ZSH % ls test* # Error: ls not executed zsh: no matches found: test* % print -- test* # Error: print not executed zsh: no matches found: test* % setopt NO_NOMATCH # Disables this option % ls test* # ls is now executed with test* a parameter ls: cannot access test*: No such file or directory % print -- test* # print is now executed test*
setopt NOMATCHsetopt NOMATCH% cd ~ % ls test* zsh: no matches found: test* % setopt NULL_GLOB # Activate this option % ls test* # Removes the pattern, hence issues 'ls' only bin Documents Downloads Games Pictures Public
If activated, this option removes any filename generation pattern that does not match anything; hence, no error will be reported as done by the NOMATCH option, as this option is completely overriden.
setopt NO_NULL_GLOBsetopt NO_NULL_GLOBCheck userguide 5.4.5
See 5.9.3 “Parentheses” in the user guide.
If set, all parameters that are subsequently defined will be exported,
even if the export keyword is not explicitly given. This means that
the parameters will be accessible from any other command (they can find
the variable in their environment) started from
this zsh instance; they will not remain purely local.
This option might be useful for you if you start many subshells that should have exactly the same environment as the starting shell.
% TEST=5 % zsh # Start a 2nd shell % echo $TEST # Empty! % exit # Close the 2nd shell % setopt ALL_EXPORT % FOO=5 % zsh % echo $FOO # Found FOO! 5
setopt NO_ALL_EXPORTsetopt NO_ALL_EXPORTWith this option you can disable aliases (as they are enabled by default); see the corresponding manual page for details on what aliases are and what they do.
setopt ALIASESWithin single-quoted strings, ” will mean the same as ‘.
ZSH tries to protect the user from accidentally deleting all files in a directory;
that is, ZSH complains when rm is used and a * occurs in your filematching
pattern; ZSH does not complain, however, if you deliberately expand this pattern
(as you will see exactly which files are selected).
% rm ./* zsh: sure you want to delete all the files in /tmp/test/. [yn]?
This is helpful to prevent you from wiping your data accidentally; in case you don’t want to confirm that you’re really sure, turn this option on - ZSH will not ask again.
setopt NO_RM_STAR_SILENTIf #RM_STAR_SILENT is not set (that is, you need to confirm if you try
to issue rm * and friends), setting this option makes you wait for
ten seconds before you can even answer “yes” or “no”.
The motivation for this option is to prevent the user from hitting “yes” in a reflex.
Note: If you expand the *, you do not have to wait ten seconds to delete
the files you want. This is helpful if you really want to use the *.
% rm ./* zsh: sure you want to delete all the files in /tmp/test/.? (waiting ten seconds) [yn] # This line only appears after ten seconds!
setopt NO_RM_STAR_SILENTWhen starting jobs from your shell, they are owned by that shell and exhibit behavior that is often
dependent on the shell‘s process; for instance, if you send a SIGHUP (signal hang up) to the shell,
that signal would also be send to all jobs executed under that shell. (See the output of the jobs
command if there are any.)
zsh─┬─eog───5*[{eog}]
└─some_other_process
If you want to remove a process from a shell‘s job list (and hence change the way it responds to,
e.g., a SIGHUP) you can use the builtin disown to do so. Once you have disowned the process, you can
no longer use bg and fg on that process to run it in the background or the foreground.
What AUTO_CONTINUE does is that it automatically sends a SIGCONT (signal continue) to the process
when disown is used.
% unsetopt AUTO_CONTINUE % eog . # Now I press Control-Z in order to move the process to the background; this is because I have # used the following in my config: # zle -N foreground-vi # bindkey '^Z' foreground-vi zsh: suspended eog . % jobs [1] + suspended eog . % # Typing exit here would kill the subprocess as well % # Typing kill %1 would kill the subprocess (but not the shell) % disown %1 disown: warning: job is suspended, use `kill -CONT -82336' to resume # The process is still halted, hence cannot be used. However, you could send a SIGCONT manually to # the process to continue it: kill -CONT -82336 % jobs # No output, as no more jobs are active % kill %1 kill: %1: no such job % kill 82336 # Kill the above process # And now for the opposite ... % setopt AUTO_CONTINUE % eog . ^Z # See above (foreground-vi) zsh: suspended eog . % disown %1 [1] + continued eog . # The CONT signal is now sent automatically % jobs % # Still no jobs!
setopt AUTO_CONTINUEsetopt NO_AUTO_CONTINUESimple commands (i.e., just the command-name, nothing else) that do not
use redirection will be used to resume background jobs of that same
command. For instance, if you have an instance of top in the
background and re-execute the top command (without any arguments or
redirection), the sleeping process will be resumed; if this option
is not set, top would be executed a second time.
% setopt NO_AUTO_RESUME % top # Now CTRL-Z % top # CTRL-Z again % ps PID TTY TIME CMD 7191 pts/9 00:00:00 zsh 7192 pts/9 00:00:00 top 7193 pts/9 00:00:00 top 7194 pts/9 00:00:00 ps % killall top % setopt AUTO_RESUME % top # CTRL-Z % top # CTRL-Z % ps # Only one (not two!) top instance running! PID TTY TIME CMD 7191 pts/9 00:00:00 zsh 7237 pts/9 00:00:00 top 7238 pts/9 00:00:00 ps
setopt NO_AUTO_RESUMEsetopt NO_AUTO_RESUMEIf set, all jobs that will be started in the background will be nice
towards other jobs, that is, they will run at a lower priority.
(See man 1 nice for details.)
This option, however, does not change the level of niceness for jobs that were started and then moved to the background (for instance, by pressing CTRL-Z).
% setopt BG_NICE # This is the default % top # Now press CTRL-Z; top will not be "nice" % ps au USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND ch 6257 0.2 0.0 25228 4224 pts/8 T 17:55 0:00 top % kill top % top & # Start top in the background % ps au # This will output "N" in the "STAT" column ch 6385 0.0 0.0 16320 3612 pts/8 TN 17:58 0:00 top % kill top % setopt NO_BG_NICE % top & # Start top in the background % ps au # top will not be nice any more! ch 6463 0.3 0.0 25112 4224 pts/8 T 18:00 0:00 top
setopt BG_NICEsetopt BG_NICEReports status of suspended and background jobs when trying to exit the shell. If disabled, jobs will be killed automatically if #OPTION_HUP is activated.
Hint: if the previous command line contains the jobs command, this check is omitted. (Hook functions
as defined under Special Functions in the manual (see zsh: 9 Functions)
% setopt CHECK_JOBS % eog . & [1] 86845 % exit zsh: you have running jobs. % # exit # second exit command would actually exit % setopt NO_CHECK_JOBS % exit zsh: warning: 1 jobs SIGHUPed
setopt CHECK_JOBSsetopt CHECK_JOBSThis option is enabled by default in ZSH and will cause ZSH
to send the HUP (hang up) signal to be sent to any background
process if the shell is going to terminate (i.e., you used one of
exit~, logout, bye etc. or a non-interactive shell started
background jobs).
That is, with this option unset, jobs will continue to run normall when the shell exits.
# First shell
% setopt NO_HUP
% sleep 500 &
[1] 20931
% exit
zsh: you have running jobs.
% exit # 2nd exit = exits. See also CHECK_JOBS option.
# Executed in a 2nd shell!
% ps auxw | grep "sleep"
ch 20988 0.0 0.0 13064 608 pts/8 SN 01:04 0:00 sleep 500
# Start a new shell...
% setopt HUP
% sleep 500 &
[1] 21168
% exit
zsh: you have running jobs.
% exit # 2nd exit = exits. See also CHECK_JOBS option.
# Executed in a 2nd shell!
% ps auxw | grep "sleep" # Returns nothing, as process was killed!
# (for you, it may return 20931 from above...)
% # Yup, nothing there...
setopt HUPsetopt HUPIf activated, jobs will be listed using the long format; that is, when the job terminates, ZSH will also tell you the process id this job had.
This option has no effect if the MONITOR option is turned off.
% setopt LONG_LIST_JOBS % sleep 5 & [1] 20241 % [1] + 20241 done sleep 5 # Includes process id! % setopt NO_LONG_LIST_JOBS % sleep 5 & [1] 20330 % [1] + done sleep 5 # ... not anymore!
setopt LONG_LIST_JOBSsetopt NO_LONG_LIST_JOBSIn ZSH, this option is enabled by default for interactive shells (that is, shells that accept commands from you instead of reading them from a file). It’s behavior is quite simply:
If activated, starting a job and putting it in the background right away
by using the & sign at the end of the command will notify you about
the job number (a value local to this shell) and the process number
this new process was given by the operating system. You will furthermore
be notified when this process ends (you can determine when you want to
be notified by (un-)setting the NOTIFY option).
% setopt MONITOR % sleep 3 & [1] 20058 # This output line was caused by this option % seto # We start typing... but we're interrupted [1] + done sleep 3 % setopt NO_MONITOR # ... but we can continue typing after "seto"! % sleep 5 & % # Nothing happens; we won't get notifications
setopt MONITORsetopt MONITORReports the status of background jobs immediately (i.e., jobs you’ve
started from this shell by for instance adding the & character
at the end of your command). If disabled, you will only be notified
about the termination of your job when a new prompt is printed.
% setopt NOTIFY # It's always enabled by default % sleep 3 & [1] 19316 % # Don't do anything now, just wait 3seconds... [1] + done sleep 3 % # We didn't do anything; but a new prompt was printed! % setopt NO_NOTIFY # Now disable it... % sleep 3 & % # Nothing will appear now, until you hit return.. [1] + done sleep 3
setopt NOTIFYsetopt NOTIFYMany options in ZSH also have one-letter shortcuts assigned to them, making it very quick to enable/disable specific options; in fact, there are two different sets of one-letter options. The first one is the “default” zsh set and used by default; the second one is used to emulate sh/ksh options.
Take for example the NOTIFY option: The default one-char option is -5,
but if SH_OPTION_LETTERS is set, the one-character option becomes -b.
% setopt NO_SH_OPTION_LETTERS # Default % setopt -b # Try to set the NOTIFY option setopt: bad option: -b % setopt SH_OPTION_LETTERS % setopt -b # This command was now successful
setopt NO_SH_OPTION_LETTERSsetopt NO_SH_OPTION_LETTERSSee userguide 5.4.4
This option starts ZSH in overstrike mode; to quote Wikipedia:
In typography, overstrike is a method of printing characters that are missing from the printer’s character set. The character was created by placing one character on another one — for example, overstriking “L” with “-” resulted in printing a “Ł” character.
setopt NO_OVERSTRIKEsetopt NO_OVERSTRIKEThis option changes the ZSH keybindings (for interactive shells) to behave like VI; for emacs users, option EMACS is
This option, if enabled, does the same as
% bindkey -v # Enables the vi-keymap % unsetopt EMACS
Unsetting this option, on the other hand, has no effect.
Please note that just because this option is set, the vi-keybindings are not guaranteed to be enabled (i.e., your scripts must not rely on this option to determine whether the vi-keymap is activated or not):
% setopt VI % bindkey -lL main bindkey -A viins main % bindkey -e % bindkey -lL main bindkey -A emacs main % [[ -o VI ]] && print "VI still enabled!" VI still enabled!
This option is just provided for compatibility reasons; you should
always prefer to use the bindkey builtin.
setopt VIsetopt NO_VIThese are aliases for the options above, as seen in section 16.3 of the manual.
Migrate these aliases to the options above, use the :PROPERTIES: drawer and define a property such as “ALIAS”.
Equivalent to unsetting #OPTION_IGNORE_BRACES, i.e., setopt NO_IGNORE_BRACES. (Used for ksh and bash compatibility.)
Equivalent to setting #OPTION_GLOB_DOTS, i.e., setopt GLOB_DOTS. (Used for bash compatibility.)
Equivalent to setting #OPTION_HASH_CMDS, i.e., setopt HASH_CMDS. (Used for bash compatibility.)
Equivalent to setting #OPTION_APPEND_HISTORY, i.e., setopt APPEND_HISTORY. (Used for bash compatibility.)
Equivalent to setting #OPTION_BANG_HIST, i.e., setopt BANG_HIST. (Used for bash compatibility.)
Equivalent to unsetting #OPTION_HIST_NO_FUNCTIONS, i.e., setopt NO_HIST_NO_FUNCTIONS. (Used for ksh compatibility.)
Equivalent to setting #OPTION_MAIL_WARNING, i.e., setopt MAIL_WARNING. (Used for bash compatibility.)
Equivalent to setting #OPTION_SINGLE_COMMAND, i.e., setopt SINGLE_COMMAND. (Used for bash compatibility.)
Equivalent to setting #OPTION_CHASE_LINKS, i.e., setopt CHASE_LINKS. (Used for ksh and bash compatibility.)
Equivalent to setting #OPTION_PROMPT_SUBST, i.e., setopt PROMPT_SUBST. (Used for bash compatibility.)
Equivalent to setting #OPTION_SHIN_STDIN, i.e., setopt SHIN_STDIN. (Used for ksh compatibility.)
Equivalent to setting #OPTION_HASH_CMDS, i.e., setopt HASH_CMDS. (Used for ksh compatibility.)
Migrate these aliases to the options above, use the :PROPERTIES: drawer and define a property such as “SINGLE_LETTER”.
The single letters are already present in the headlines above, such as (-4) etc.