diff options
author | Christian Clason <c.clason@uni-graz.at> | 2022-04-09 11:19:18 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-09 11:19:18 +0200 |
commit | 8055f9857b8e384634d457533dfdb08618fc36f0 (patch) | |
tree | 8b1c4231f18b5cb9c15b35f39d16f20a80092fcb | |
parent | b259426a257c25bc219b8463e9fcd220f2c8c9ef (diff) | |
download | rneovim-8055f9857b8e384634d457533dfdb08618fc36f0.tar.gz rneovim-8055f9857b8e384634d457533dfdb08618fc36f0.tar.bz2 rneovim-8055f9857b8e384634d457533dfdb08618fc36f0.zip |
vim-patch:8.2.4715: Vagrantfile not recognized (#18052)
Problem: Vagrantfile not recognized.
Solution: Recognize Vagrantfile as ruby. (Julien Voisin, closes vim/vim#10119)
https://github.com/vim/vim/commit/5e1792270a072a96157e5d5e1d6a97414e26d0bf
-rw-r--r-- | runtime/filetype.vim | 3 | ||||
-rw-r--r-- | runtime/lua/vim/filetype.lua | 1 | ||||
-rw-r--r-- | src/nvim/testdir/test_filetype.vim | 2 |
3 files changed, 5 insertions, 1 deletions
diff --git a/runtime/filetype.vim b/runtime/filetype.vim index 677eda8ad7..255414aca6 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -2049,6 +2049,9 @@ au BufNewFile,BufRead *.vala setf vala " Vera au BufNewFile,BufRead *.vr,*.vri,*.vrh setf vera +" Vagrant (uses Ruby syntax) +au BufNewFile,BufRead Vagrantfile setf ruby + " Verilog HDL au BufNewFile,BufRead *.v setf verilog diff --git a/runtime/lua/vim/filetype.lua b/runtime/lua/vim/filetype.lua index 6d8f734bed..7958de97b1 100644 --- a/runtime/lua/vim/filetype.lua +++ b/runtime/lua/vim/filetype.lua @@ -1061,6 +1061,7 @@ local filename = { Puppetfile = "ruby", [".irbrc"] = "ruby", irbrc = "ruby", + Vagrantfile = "ruby", ["smb.conf"] = "samba", screenrc = "screen", [".screenrc"] = "screen", diff --git a/src/nvim/testdir/test_filetype.vim b/src/nvim/testdir/test_filetype.vim index 42271a014d..9feab735e4 100644 --- a/src/nvim/testdir/test_filetype.vim +++ b/src/nvim/testdir/test_filetype.vim @@ -455,7 +455,7 @@ let s:filename_checks = { \ 'rpl': ['file.rpl'], \ 'rst': ['file.rst'], \ 'rtf': ['file.rtf'], - \ 'ruby': ['.irbrc', 'irbrc', 'file.rb', 'file.rbw', 'file.gemspec', 'file.ru', 'Gemfile', 'file.builder', 'file.rxml', 'file.rjs', 'file.rant', 'file.rake', 'rakefile', 'Rakefile', 'rantfile', 'Rantfile', 'rakefile-file', 'Rakefile-file', 'Puppetfile'], + \ 'ruby': ['.irbrc', 'irbrc', 'file.rb', 'file.rbw', 'file.gemspec', 'file.ru', 'Gemfile', 'file.builder', 'file.rxml', 'file.rjs', 'file.rant', 'file.rake', 'rakefile', 'Rakefile', 'rantfile', 'Rantfile', 'rakefile-file', 'Rakefile-file', 'Puppetfile', 'Vagrantfile'], \ 'rust': ['file.rs'], \ 'samba': ['smb.conf'], \ 'sas': ['file.sas'], |