aboutsummaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2021-12-04 12:26:37 +0100
committerGitHub <noreply@github.com>2021-12-04 12:26:37 +0100
commit2ccf6567b7ca0456d13e8fb32ea7b111a6de197e (patch)
treec96b32f48b244f0137582e4c7e33552caa15cb10 /runtime
parent419e0d117d61f6d22f696a8833541dd1691c92fb (diff)
downloadrneovim-2ccf6567b7ca0456d13e8fb32ea7b111a6de197e.tar.gz
rneovim-2ccf6567b7ca0456d13e8fb32ea7b111a6de197e.tar.bz2
rneovim-2ccf6567b7ca0456d13e8fb32ea7b111a6de197e.zip
vim-patch:8.2.3730: "/etc/Muttrc.d/README" gets filetype muttrc (#16515)
Problem: "/etc/Muttrc.d/README" gets filetype muttrc. Solution: Move the Muttrc.d pattern down, add exception for *.rc files. https://github.com/vim/vim/commit/800b01b0c8a5983e23d8caa2be6c73d195448193
Diffstat (limited to 'runtime')
-rw-r--r--runtime/filetype.vim12
1 files changed, 8 insertions, 4 deletions
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index f6e1028e31..f0285c09d0 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -1119,14 +1119,15 @@ au BufNewFile,BufRead *.msql setf msql
" Mysql
au BufNewFile,BufRead *.mysql setf mysql
-" Mutt setup files (must be before catch *.rc)
-au BufNewFile,BufRead */etc/Muttrc.d/* call s:StarSetf('muttrc')
-
" Tcl Shell RC file
au BufNewFile,BufRead tclsh.rc setf tcl
" M$ Resource files
-au BufNewFile,BufRead *.rc,*.rch setf rc
+" /etc/Muttrc.d/file.rc is muttrc
+au BufNewFile,BufRead *.rc,*.rch
+ \ if expand("<afile>") !~ "/etc/Muttrc.d/" |
+ \ setf rc |
+ \ endif
" MuPAD source
au BufRead,BufNewFile *.mu setf mupad
@@ -2285,6 +2286,9 @@ au BufNewFile,BufRead */etc/modutils/*
\|endif
au BufNewFile,BufRead */etc/modprobe.* call s:StarSetf('modconf')
+" Mutt setup files (must be before catch *.rc)
+au BufNewFile,BufRead */etc/Muttrc.d/* call s:StarSetf('muttrc')
+
" Mutt setup file
au BufNewFile,BufRead .mutt{ng,}rc*,*/.mutt{ng,}/mutt{ng,}rc* call s:StarSetf('muttrc')
au BufNewFile,BufRead mutt{ng,}rc*,Mutt{ng,}rc* call s:StarSetf('muttrc')