forked from aniani/vim
patch 9.1.0244: filetype: bash history files are not recognized
Problem: filetype: bash history files are not recognized
Solution: detect .bash-history and .bash_history files as bash
(Wu, Zhenyu)
closes: #14365
Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
committed by
Christian Brabandt
parent
abbb4a4f70
commit
84ce55001a
@@ -2020,7 +2020,7 @@ au BufNewFile,BufRead catalog setf catalog
|
|||||||
" Gentoo ebuilds, Arch Linux PKGBUILDs and Alpine Linux APKBUILDs are actually
|
" Gentoo ebuilds, Arch Linux PKGBUILDs and Alpine Linux APKBUILDs are actually
|
||||||
" bash scripts.
|
" bash scripts.
|
||||||
" NOTE: Patterns ending in a star are further down, these have lower priority.
|
" NOTE: Patterns ending in a star are further down, these have lower priority.
|
||||||
au BufNewFile,BufRead .bashrc,bashrc,bash.bashrc,.bash[_-]profile,.bash[_-]logout,.bash[_-]aliases,bash-fc[-.],*.ebuild,*.bash,*.eclass,PKGBUILD,APKBUILD,*.bats call dist#ft#SetFileTypeSH("bash")
|
au BufNewFile,BufRead .bashrc,bashrc,bash.bashrc,.bash[_-]profile,.bash[_-]logout,.bash[_-]aliases,.bash[_-]history,bash-fc[-.],*.ebuild,*.bash,*.eclass,PKGBUILD,APKBUILD,*.bats call dist#ft#SetFileTypeSH("bash")
|
||||||
au BufNewFile,BufRead .kshrc,*.ksh call dist#ft#SetFileTypeSH("ksh")
|
au BufNewFile,BufRead .kshrc,*.ksh call dist#ft#SetFileTypeSH("ksh")
|
||||||
au BufNewFile,BufRead */etc/profile,.profile,*.sh,*.env call dist#ft#SetFileTypeSH(getline(1))
|
au BufNewFile,BufRead */etc/profile,.profile,*.sh,*.env call dist#ft#SetFileTypeSH(getline(1))
|
||||||
|
|
||||||
|
|||||||
@@ -622,7 +622,7 @@ def s:GetFilenameChecks(): dict<list<string>>
|
|||||||
services: ['/etc/services', 'any/etc/services'],
|
services: ['/etc/services', 'any/etc/services'],
|
||||||
setserial: ['/etc/serial.conf', 'any/etc/serial.conf'],
|
setserial: ['/etc/serial.conf', 'any/etc/serial.conf'],
|
||||||
sexplib: ['file.sexp'],
|
sexplib: ['file.sexp'],
|
||||||
sh: ['.bashrc', '.bash_profile', '.bash-profile', '.bash_logout', '.bash-logout', '.bash_aliases', '.bash-aliases', '/tmp/bash-fc-3Ozjlw', '/tmp/bash-fc.3Ozjlw', 'PKGBUILD', 'APKBUILD', 'file.bash', '/usr/share/doc/bash-completion/filter.sh', '/etc/udev/cdsymlinks.conf', 'any/etc/udev/cdsymlinks.conf', 'file.bats'],
|
sh: ['.bashrc', '.bash_profile', '.bash-profile', '.bash_logout', '.bash-logout', '.bash_aliases', '.bash-aliases', '.bash_history', '.bash-history', '/tmp/bash-fc-3Ozjlw', '/tmp/bash-fc.3Ozjlw', 'PKGBUILD', 'APKBUILD', 'file.bash', '/usr/share/doc/bash-completion/filter.sh', '/etc/udev/cdsymlinks.conf', 'any/etc/udev/cdsymlinks.conf', 'file.bats'],
|
||||||
sieve: ['file.siv', 'file.sieve'],
|
sieve: ['file.siv', 'file.sieve'],
|
||||||
sil: ['file.sil'],
|
sil: ['file.sil'],
|
||||||
simula: ['file.sim'],
|
simula: ['file.sim'],
|
||||||
|
|||||||
@@ -704,6 +704,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
244,
|
||||||
/**/
|
/**/
|
||||||
243,
|
243,
|
||||||
/**/
|
/**/
|
||||||
|
|||||||
Reference in New Issue
Block a user