forked from aniani/vim
patch 9.1.1030: filetype: setting bash filetype is backwards incompatible
Problem: filetype: setting bash filetype is backwards incompatible
Solution: revert patch v9.1.0965, detect bash scripts again as sh
filetype
This reverts commit b9b762c21f
.
related: #16309
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
1
runtime/autoload/dist/ft.vim
vendored
1
runtime/autoload/dist/ft.vim
vendored
@@ -900,7 +900,6 @@ export def SetFileTypeSH(name: string, setft = true): string
|
|||||||
if exists("b:is_sh")
|
if exists("b:is_sh")
|
||||||
unlet b:is_sh
|
unlet b:is_sh
|
||||||
endif
|
endif
|
||||||
return SetFileTypeShell("bash", setft)
|
|
||||||
elseif name =~ '\<sh\>' || name =~ '\<dash\>'
|
elseif name =~ '\<sh\>' || name =~ '\<dash\>'
|
||||||
# Ubuntu links "sh" to "dash", thus it is expected to work the same way
|
# Ubuntu links "sh" to "dash", thus it is expected to work the same way
|
||||||
b:is_sh = 1
|
b:is_sh = 1
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
*version9.txt* For Vim version 9.1. Last change: 2025 Jan 16
|
*version9.txt* For Vim version 9.1. Last change: 2025 Jan 18
|
||||||
|
|
||||||
|
|
||||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||||
@@ -41617,8 +41617,6 @@ Changed~
|
|||||||
|CompleteDone| autocommand in the |v:event| dictionary
|
|CompleteDone| autocommand in the |v:event| dictionary
|
||||||
- the default fontsize for the GTK builds of Vim (Windows and Unix) has been
|
- the default fontsize for the GTK builds of Vim (Windows and Unix) has been
|
||||||
increased to 12pt to accomodate modern high-dpi monitors
|
increased to 12pt to accomodate modern high-dpi monitors
|
||||||
- filetype detection now detects bash scripts as a separate "bash" filetype
|
|
||||||
instead of the "sh" filetype
|
|
||||||
- the default value of the 'keyprotocol' option has been updated by support
|
- the default value of the 'keyprotocol' option has been updated by support
|
||||||
for the ghostty terminal emulator (using kitty protocol)
|
for the ghostty terminal emulator (using kitty protocol)
|
||||||
- |complete_info()| returns the list of matches shown in the poppu menu via
|
- |complete_info()| returns the list of matches shown in the poppu menu via
|
||||||
|
@@ -127,10 +127,6 @@ def s:GetFilenameChecks(): dict<list<string>>
|
|||||||
ave: ['file.ave'],
|
ave: ['file.ave'],
|
||||||
awk: ['file.awk', 'file.gawk'],
|
awk: ['file.awk', 'file.gawk'],
|
||||||
b: ['file.mch', 'file.ref', 'file.imp'],
|
b: ['file.mch', 'file.ref', 'file.imp'],
|
||||||
bash: ['.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',
|
|
||||||
'file.bash', 'file.bats', 'file.cygport'],
|
|
||||||
basic: ['file.bas', 'file.bi', 'file.bm'],
|
basic: ['file.bas', 'file.bi', 'file.bm'],
|
||||||
bass: ['file.bass'],
|
bass: ['file.bass'],
|
||||||
bc: ['file.bc'],
|
bc: ['file.bc'],
|
||||||
@@ -690,13 +686,11 @@ 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: ['/usr/share/doc/bash-completion/filter.sh',
|
sh: ['.bashrc', '.bash_profile', '.bash-profile', '.bash_logout', '.bash-logout', '.bash_aliases', '.bash-aliases', '.bash_history', '.bash-history',
|
||||||
'/etc/udev/cdsymlinks.conf', 'any/etc/udev/cdsymlinks.conf',
|
'/tmp/bash-fc-3Ozjlw', '/tmp/bash-fc.3Ozjlw', 'PKGBUILD', 'file.bash', '/usr/share/doc/bash-completion/filter.sh',
|
||||||
'.ash_history', 'any/etc/neofetch/config.conf', '.xprofile',
|
'/etc/udev/cdsymlinks.conf', 'any/etc/udev/cdsymlinks.conf', 'file.bats', '.ash_history', 'any/etc/neofetch/config.conf', '.xprofile',
|
||||||
'user-dirs.defaults', 'user-dirs.dirs', 'makepkg.conf', '.makepkg.conf',
|
'user-dirs.defaults', 'user-dirs.dirs', 'makepkg.conf', '.makepkg.conf', 'file.mdd', 'file.cygport', '.env', '.envrc', 'devscripts.conf',
|
||||||
'file.mdd', '.env', '.envrc', 'devscripts.conf', '.devscripts', 'file.lo',
|
'.devscripts', 'file.lo', 'file.la', 'file.lai'],
|
||||||
'file.la', 'file.lai'],
|
|
||||||
shaderslang: ['file.slang'],
|
|
||||||
sieve: ['file.siv', 'file.sieve'],
|
sieve: ['file.siv', 'file.sieve'],
|
||||||
sil: ['file.sil'],
|
sil: ['file.sil'],
|
||||||
simula: ['file.sim'],
|
simula: ['file.sim'],
|
||||||
@@ -988,11 +982,11 @@ def s:GetScriptChecks(): dict<list<list<string>>>
|
|||||||
clojure: [['#!/path/clojure']],
|
clojure: [['#!/path/clojure']],
|
||||||
scala: [['#!/path/scala']],
|
scala: [['#!/path/scala']],
|
||||||
sh: [['#!/path/sh'],
|
sh: [['#!/path/sh'],
|
||||||
|
['#!/path/bash'],
|
||||||
|
['#!/path/bash2'],
|
||||||
['#!/path/dash'],
|
['#!/path/dash'],
|
||||||
['#!/path/ksh'],
|
['#!/path/ksh'],
|
||||||
['#!/path/ksh93']],
|
['#!/path/ksh93']],
|
||||||
bash: [['#!/path/bash'],
|
|
||||||
['#!/path/bash2']],
|
|
||||||
csh: [['#!/path/csh']],
|
csh: [['#!/path/csh']],
|
||||||
tcsh: [['#!/path/tcsh']],
|
tcsh: [['#!/path/tcsh']],
|
||||||
zsh: [['#!/path/zsh']],
|
zsh: [['#!/path/zsh']],
|
||||||
|
@@ -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 */
|
||||||
|
/**/
|
||||||
|
1030,
|
||||||
/**/
|
/**/
|
||||||
1029,
|
1029,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user