aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2021-05-08 12:54:31 -0400
committerGitHub <noreply@github.com>2021-05-08 12:54:31 -0400
commitf8173df4d7ecec239629921736340d3f4d1dcfd4 (patch)
tree530156b34c603f3ba19abc0ee5a52a17e1ab3e33
parentcd5fde6e6c3471479da831a220dec5a88e311e3e (diff)
parentec04d371882a55c370700dd73e1419cbc130c942 (diff)
downloadrneovim-f8173df4d7ecec239629921736340d3f4d1dcfd4.tar.gz
rneovim-f8173df4d7ecec239629921736340d3f4d1dcfd4.tar.bz2
rneovim-f8173df4d7ecec239629921736340d3f4d1dcfd4.zip
Merge pull request #14517 from janlazo/vim-8.2.2838
vim-patch:8.2.{2838,2839}
-rw-r--r--runtime/doc/options.txt6
-rw-r--r--runtime/filetype.vim1
-rw-r--r--src/nvim/option.c21
-rw-r--r--src/nvim/testdir/test_filetype.vim2
4 files changed, 17 insertions, 13 deletions
diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt
index 269080e750..2527a91cc8 100644
--- a/runtime/doc/options.txt
+++ b/runtime/doc/options.txt
@@ -5267,9 +5267,9 @@ A jump table for the options with a short description can be found at |Q_op|.
in a file and echoed to the screen. If the 'shell' option is "csh" or
"tcsh" after initializations, the default becomes "|& tee". If the
'shell' option is "sh", "ksh", "mksh", "pdksh", "zsh", "zsh-beta",
- "bash" or "fish" the default becomes "2>&1| tee". This means that
- stderr is also included. Before using the 'shell' option a path is
- removed, thus "/bin/sh" uses "sh".
+ "bash", "fish", "ash" or "dash" the default becomes "2>&1| tee". This
+ means that stderr is also included. Before using the 'shell' option a
+ path is removed, thus "/bin/sh" uses "sh".
The initialization of this option is done after reading the vimrc
and the other initializations, so that when the 'shell' option is set
there, the 'shellpipe' option changes automatically, unless it was
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index f0d2b36a84..474a447284 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -1015,6 +1015,7 @@ au BufNewFile,BufRead *.hgrc,*hgrc setf cfg
" Meson Build system config
au BufNewFile,BufRead meson.build,meson_options.txt setf meson
+au BufNewFile,BufRead *.wrap setf dosini
" Messages (logs mostly)
au BufNewFile,BufRead */log/{auth,cron,daemon,debug,kern,lpr,mail,messages,news/news,syslog,user}{,.log,.err,.info,.warn,.crit,.notice}{,.[0-9]*,-[0-9]*} setf messages
diff --git a/src/nvim/option.c b/src/nvim/option.c
index a811d749b9..6f28f37d2b 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -855,15 +855,18 @@ void set_init_3(void)
p_srr = (char_u *)">&";
options[idx_srr].def_val[VI_DEFAULT] = p_srr;
}
- } else if ( fnamecmp(p, "sh") == 0
- || fnamecmp(p, "ksh") == 0
- || fnamecmp(p, "mksh") == 0
- || fnamecmp(p, "pdksh") == 0
- || fnamecmp(p, "zsh") == 0
- || fnamecmp(p, "zsh-beta") == 0
- || fnamecmp(p, "bash") == 0
- || fnamecmp(p, "fish") == 0
- ) {
+ } else if (fnamecmp(p, "sh") == 0
+ || fnamecmp(p, "ksh") == 0
+ || fnamecmp(p, "mksh") == 0
+ || fnamecmp(p, "pdksh") == 0
+ || fnamecmp(p, "zsh") == 0
+ || fnamecmp(p, "zsh-beta") == 0
+ || fnamecmp(p, "bash") == 0
+ || fnamecmp(p, "fish") == 0
+ || fnamecmp(p, "ash") == 0
+ || fnamecmp(p, "dash") == 0
+ ) {
+ // Always use POSIX shell style redirection if we reach this
if (do_sp) {
p_sp = (char_u *)"2>&1| tee";
options[idx_sp].def_val[VI_DEFAULT] = p_sp;
diff --git a/src/nvim/testdir/test_filetype.vim b/src/nvim/testdir/test_filetype.vim
index 6b1e484c3a..056b953d0b 100644
--- a/src/nvim/testdir/test_filetype.vim
+++ b/src/nvim/testdir/test_filetype.vim
@@ -148,7 +148,7 @@ let s:filename_checks = {
\ 'dnsmasq': ['/etc/dnsmasq.conf', '/etc/dnsmasq.d/file', 'any/etc/dnsmasq.conf', 'any/etc/dnsmasq.d/file'],
\ 'dockerfile': ['Containerfile', 'Dockerfile', 'file.Dockerfile'],
\ 'dosbatch': ['file.bat', 'file.sys'],
- \ 'dosini': ['.editorconfig', '/etc/pacman.conf', '/etc/yum.conf', 'file.ini', 'npmrc', '.npmrc', 'php.ini', 'php.ini-5', 'php.ini-file', '/etc/yum.repos.d/file', 'any/etc/pacman.conf', 'any/etc/yum.conf', 'any/etc/yum.repos.d/file'],
+ \ 'dosini': ['.editorconfig', '/etc/pacman.conf', '/etc/yum.conf', 'file.ini', 'npmrc', '.npmrc', 'php.ini', 'php.ini-5', 'php.ini-file', '/etc/yum.repos.d/file', 'any/etc/pacman.conf', 'any/etc/yum.conf', 'any/etc/yum.repos.d/file', 'file.wrap'],
\ 'dot': ['file.dot', 'file.gv'],
\ 'dracula': ['file.drac', 'file.drc', 'filelvs', 'filelpe', 'drac.file', 'lpe', 'lvs', 'some-lpe', 'some-lvs'],
\ 'dsl': ['file.dsl'],