From 90ffd5eb85cf4c46db27f8cc4bb6df3d088fe81d Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Tue, 11 Jun 2019 09:51:15 +1200 Subject: Use dedicated augroup for local spellfile --- vim/plugin/spellfile_local.vim | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/vim/plugin/spellfile_local.vim b/vim/plugin/spellfile_local.vim index b5db4518..285618f8 100644 --- a/vim/plugin/spellfile_local.vim +++ b/vim/plugin/spellfile_local.vim @@ -23,7 +23,11 @@ function! AddLocalSpellfile() abort execute 'setlocal spellfile+=$MYVIM/cache/spell/local/'.spellfile nnoremap zG 2zg endfunction -autocmd vimrc BufRead * command! AddLocalSpellFile \ call AddLocalSpellFile() + +augroup spellfile_local + autocmd BufRead * + \ AddLocalSpellfile +augroup END -- cgit v1.2.3