From 485039af392f4a3159f8b48c502f9177bd7a3438 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Wed, 5 Jun 2019 12:21:06 +1200 Subject: Spellcheck mail --- vim/after/ftplugin/mail.vim | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'vim/after') diff --git a/vim/after/ftplugin/mail.vim b/vim/after/ftplugin/mail.vim index 937ee40c..e84702f0 100644 --- a/vim/after/ftplugin/mail.vim +++ b/vim/after/ftplugin/mail.vim @@ -78,6 +78,12 @@ if exists('loaded_squeeze_repeat_blanks') endif +" Spellcheck documents we're actually editing (not just viewing) +if &modifiable && !&readonly + setlocal spell + let b:undo_ftplugin .= '|setlocal spell<' +endif + " Stop here if the user doesn't want ftplugin mappings if exists('no_plugin_maps') || exists('no_mail_maps') finish -- cgit v1.2.3