On Do, 07 Jan 2021, Matthias Apitz wrote:
> I do use in ~/.muttrc > > set editor="vim \'+set textwidth=72\' \'+syntax match WarningMsg > /\\%>70v.*/\' -i NONE" If Vim is setup with filetype detection logic, it automatically knows you are editing a mail filetype, because it recognizes the path. For this you need a `:filetype plugin on` in your .vimrc. Then place your filetype specific settings in a file called ~/.vim/after/ftplugin/mail.vim (create non-existing directories; depending on your needs, one may leave out the after directory). If you have several files you need to read in, you can alternatively place them all in a directory ~/.vim/after/ftplugin/mail/ Also, you usually want to set buffer local settings, so use `:setl` instead of `:set` or `:setg`. I have described my setup here: https://www.256bit.org/~chrisbra/cms/vim_as_e-mail_editor.html regards, Christian -- Whenever anyone says, "theoretically," they really mean, "not really." -- Dave Parnas