Closed marak8 closed 5 years ago
I've tried the following:
autocmd FileType muttrc setl filetype=neomuttrc<CR>
Er, that gives me an error, but without the <cr>
it works as expected:
set syn
shows "syntax=neomuttrc"The other thing I tried (and it worked) was:
autocmd BufNewFile,BufReadPost ~/.muttrc setl filetype=neomuttrc
Another alternative is to be forceful and add a Vim modeline at the end of the file
# vim: filetype=neomuttrc
Vim's help has some other suggestions under :help new-filetype
It works now, isn't it? Should this ticket be closed, or is it just working on neovim without configuration?
Currently with this plugin installed Vim sets
muttrc
filetype for~/.muttrc
. Of course you can set filetype for static paths but that's inconvenient as everyone organizes their NeoMutt configurations differently. Please see this question for what would I like to achieve: https://stackoverflow.com/questions/48104686/vim-set-filetype-in-autocmd-filetype