From 4b87248285e7d954e496f84a7ece58b4f1a830ca Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sat, 30 May 2020 18:06:23 -0400 Subject: [PATCH] vim-patch:8.2.0843: filetype elm not detected (#12403) Problem: Filetype elm not detected. Solution: Recognize *.elm files. (closes vim/vim#6157) https://github.com/vim/vim/commit/0016fd2e29b7d4d4eef89a0516d14888a8651c61 --- runtime/filetype.vim | 3 +++ src/nvim/testdir/test_filetype.vim | 1 + 2 files changed, 4 insertions(+) diff --git a/runtime/filetype.vim b/runtime/filetype.vim index 0b5003dc44..b29168984c 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -543,6 +543,9 @@ au BufNewFile,BufRead */etc/elinks.conf,*/.elinks/elinks.conf setf elinks " ERicsson LANGuage; Yaws is erlang too au BufNewFile,BufRead *.erl,*.hrl,*.yaws setf erlang +" Elm +au BufNewFile,BufRead *.elm setf elm + " Elm Filter Rules file au BufNewFile,BufRead filter-rules setf elmfilt diff --git a/src/nvim/testdir/test_filetype.vim b/src/nvim/testdir/test_filetype.vim index ace56a375f..832f1726fb 100644 --- a/src/nvim/testdir/test_filetype.vim +++ b/src/nvim/testdir/test_filetype.vim @@ -151,6 +151,7 @@ let s:filename_checks = { \ 'ecd': ['file.ecd'], \ 'edif': ['file.edf', 'file.edif', 'file.edo'], \ 'elinks': ['/etc/elinks.conf', '/.elinks/elinks.conf'], + \ 'elm': ['file.elm'], \ 'elmfilt': ['filter-rules'], \ 'erlang': ['file.erl', 'file.hrl', 'file.yaws'], \ 'eruby': ['file.erb', 'file.rhtml'],