comparison runtime/doc/options.txt @ 13162:51521b8a370c v8.0.1455

patch 8.0.1455: if $SHELL contains a space then 'shell' is incorrect commit https://github.com/vim/vim/commit/4bfa8af14142e54f509048239f4e8596911f56aa Author: Bram Moolenaar <Bram@vim.org> Date: Sat Feb 3 15:14:46 2018 +0100 patch 8.0.1455: if $SHELL contains a space then 'shell' is incorrect Problem: If $SHELL contains a space then the default value of 'shell' is incorrect. (Matthew Horan) Solution: Escape spaces in $SHELL. (Christian Brabandt, closes #459)
author Christian Brabandt <cb@256bit.org>
date Sat, 03 Feb 2018 15:15:05 +0100
parents 53cc7ea77c54
children 167a030448fa
comparison
equal deleted inserted replaced
13161:12a782ea6e51 13162:51521b8a370c
6628 value also check these options: 'shelltype', 'shellpipe', 'shellslash' 6628 value also check these options: 'shelltype', 'shellpipe', 'shellslash'
6629 'shellredir', 'shellquote', 'shellxquote' and 'shellcmdflag'. 6629 'shellredir', 'shellquote', 'shellxquote' and 'shellcmdflag'.
6630 It is allowed to give an argument to the command, e.g. "csh -f". 6630 It is allowed to give an argument to the command, e.g. "csh -f".
6631 See |option-backslash| about including spaces and backslashes. 6631 See |option-backslash| about including spaces and backslashes.
6632 Environment variables are expanded |:set_env|. 6632 Environment variables are expanded |:set_env|.
6633
6633 If the name of the shell contains a space, you might need to enclose 6634 If the name of the shell contains a space, you might need to enclose
6634 it in quotes. Example: > 6635 it in quotes or escape the space. Example with quotes: >
6635 :set shell=\"c:\program\ files\unix\sh.exe\"\ -f 6636 :set shell=\"c:\program\ files\unix\sh.exe\"\ -f
6636 < Note the backslash before each quote (to avoid starting a comment) and 6637 < Note the backslash before each quote (to avoid starting a comment) and
6637 each space (to avoid ending the option value). Also note that the 6638 each space (to avoid ending the option value). Also note that the
6638 "-f" is not inside the quotes, because it is not part of the command 6639 "-f" is not inside the quotes, because it is not part of the command
6639 name. And Vim automagically recognizes the backslashes that are path 6640 name. Vim automagically recognizes the backslashes that are path
6640 separators. 6641 separators.
6642 Example with escaped space (Vim will do this when initializing the
6643 option from $SHELL): >
6644 :set shell=/bin/with\\\ space/sh
6645 < The resulting value of 'shell' is "/bin/with\ space/sh", two
6646 backslashes are consumed by `:set`.
6647
6641 Under MS-Windows, when the executable ends in ".com" it must be 6648 Under MS-Windows, when the executable ends in ".com" it must be
6642 included. Thus setting the shell to "command.com" or "4dos.com" 6649 included. Thus setting the shell to "command.com" or "4dos.com"
6643 works, but "command" and "4dos" do not work for all commands (e.g., 6650 works, but "command" and "4dos" do not work for all commands (e.g.,
6644 filtering). 6651 filtering).
6645 For unknown reasons, when using "4dos.com" the current directory is 6652 For unknown reasons, when using "4dos.com" the current directory is