diff options
author | Christian Clason <c.clason@uni-graz.at> | 2024-02-15 00:35:54 +0100 |
---|---|---|
committer | Christian Clason <c.clason@uni-graz.at> | 2024-02-15 10:01:16 +0100 |
commit | 0a51e7626a95a068c7bb00d0da28a701fed758da (patch) | |
tree | b28a6206383c92dc9a62e20edc4994a6870d2882 | |
parent | d0599b0ed9ff77f1286f2302f92dd4e96cc98a5b (diff) | |
download | rneovim-0a51e7626a95a068c7bb00d0da28a701fed758da.tar.gz rneovim-0a51e7626a95a068c7bb00d0da28a701fed758da.tar.bz2 rneovim-0a51e7626a95a068c7bb00d0da28a701fed758da.zip |
vim-patch:9.1.0111: filetype: no support for bats files
The '*.bats' file type is for Bash Automated Testing System (BATS)
scripts. BATS scripts are Bash with a special '@test' extension but they
otherwise work with Vim's bash filetype.
See https://github.com/bats-core/bats-core
closes: vim/vim#14039
https://github.com/vim/vim/commit/d00fb4b3a237b375de5a1f453c8453b8b3797d51
Co-authored-by: Brandon Maier <brandon.maier@collins.com>
-rw-r--r-- | runtime/lua/vim/filetype.lua | 1 | ||||
-rw-r--r-- | test/old/testdir/test_filetype.vim | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/runtime/lua/vim/filetype.lua b/runtime/lua/vim/filetype.lua index 518ef13e6f..b43072a725 100644 --- a/runtime/lua/vim/filetype.lua +++ b/runtime/lua/vim/filetype.lua @@ -910,6 +910,7 @@ local extension = { sed = 'sed', sexp = 'sexplib', bash = detect.bash, + bats = detect.bash, ebuild = detect.bash, eclass = detect.bash, env = detect.sh, diff --git a/test/old/testdir/test_filetype.vim b/test/old/testdir/test_filetype.vim index 2612a92878..a49b12aee2 100644 --- a/test/old/testdir/test_filetype.vim +++ b/test/old/testdir/test_filetype.vim @@ -581,7 +581,7 @@ func s:GetFilenameChecks() abort \ 'services': ['/etc/services', 'any/etc/services'], \ 'setserial': ['/etc/serial.conf', 'any/etc/serial.conf'], \ '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'], + \ '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'], \ 'sieve': ['file.siv', 'file.sieve'], \ 'sil': ['file.sil'], \ 'simula': ['file.sim'], |