diff --git a/vim/.vim/after/ftplugin/bash.vim b/vim/.vim/after/ftplugin/bash.vim index 93ca934..ba61116 100644 --- a/vim/.vim/after/ftplugin/bash.vim +++ b/vim/.vim/after/ftplugin/bash.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use shfmt as ALE fixer for bash let b:ale_fixers=[ 'shfmt' ] let b:undo_ftplugin.='|unlet b:ale_fixers' diff --git a/vim/.vim/after/ftplugin/c.vim b/vim/.vim/after/ftplugin/c.vim index ca4a3ef..70c9c27 100644 --- a/vim/.vim/after/ftplugin/c.vim +++ b/vim/.vim/after/ftplugin/c.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " More warnings and the usual version in flags for Clang let b:ale_c_clang_options='-Wall -Wextra -pedantic -std=c99' let b:undo_ftplugin.='|unlet b:ale_c_clang_options' diff --git a/vim/.vim/after/ftplugin/cpp.vim b/vim/.vim/after/ftplugin/cpp.vim index eac9ade..81fd012 100644 --- a/vim/.vim/after/ftplugin/cpp.vim +++ b/vim/.vim/after/ftplugin/cpp.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " More warnings and the usual version in flags for Clang let b:ale_cpp_clang_options='-Wall -Wextra -pedantic -std=c++17' let b:undo_ftplugin.='|unlet b:ale_cpp_clang_options' diff --git a/vim/.vim/after/ftplugin/d.vim b/vim/.vim/after/ftplugin/d.vim index 4ade9e2..a9e13dc 100644 --- a/vim/.vim/after/ftplugin/d.vim +++ b/vim/.vim/after/ftplugin/d.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use my desired ALE fixer for D let b:ale_fixers=[ 'dfmt' ] let b:undo_ftplugin.='|unlet b:ale_fixers' diff --git a/vim/.vim/after/ftplugin/fugitive.vim b/vim/.vim/after/ftplugin/fugitive.vim index 73f936e..40e791f 100644 --- a/vim/.vim/after/ftplugin/fugitive.vim +++ b/vim/.vim/after/ftplugin/fugitive.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Don't highlight trailing whitespace in fugitive windows let b:better_whitespace_enabled=0 let b:undo_ftplugin.='|unlet b:better_whitespace_enabled' diff --git a/vim/.vim/after/ftplugin/gitcommit.vim b/vim/.vim/after/ftplugin/gitcommit.vim index 786a668..478a1b6 100644 --- a/vim/.vim/after/ftplugin/gitcommit.vim +++ b/vim/.vim/after/ftplugin/gitcommit.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Enable spell checking on commit messages setlocal spell let b:undo_ftplugin.='|setlocal spell<' diff --git a/vim/.vim/after/ftplugin/json.vim b/vim/.vim/after/ftplugin/json.vim index af3cb2b..f6d443b 100644 --- a/vim/.vim/after/ftplugin/json.vim +++ b/vim/.vim/after/ftplugin/json.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use my desired ALE fixer for JSON let b:ale_fixers=[ 'jq' ] let b:undo_ftplugin.='|unlet b:ale_fixers' diff --git a/vim/.vim/after/ftplugin/make.vim b/vim/.vim/after/ftplugin/make.vim index 1bcd00b..848c308 100644 --- a/vim/.vim/after/ftplugin/make.vim +++ b/vim/.vim/after/ftplugin/make.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Makefiles should use tabs to indent setlocal noexpandtab let b:undo_ftplugin.='|setlocal noexpandtab<' diff --git a/vim/.vim/after/ftplugin/netrw.vim b/vim/.vim/after/ftplugin/netrw.vim index f676d21..d907f44 100644 --- a/vim/.vim/after/ftplugin/netrw.vim +++ b/vim/.vim/after/ftplugin/netrw.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Don't show Netrw in buffer list setlocal bufhidden=delete let b:undo_ftplugin='|setlocal bufhidden<' diff --git a/vim/.vim/after/ftplugin/pandoc.vim b/vim/.vim/after/ftplugin/pandoc.vim index e96f98b..9aa0d8b 100644 --- a/vim/.vim/after/ftplugin/pandoc.vim +++ b/vim/.vim/after/ftplugin/pandoc.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Let ALE know that I want Markdown linters let b:ale_linter_aliases=[ 'markdown' ] let b:undo_ftplugin.='|unlet b:ale_linter_aliases' diff --git a/vim/.vim/after/ftplugin/python.vim b/vim/.vim/after/ftplugin/python.vim index c3687da..0347fcc 100644 --- a/vim/.vim/after/ftplugin/python.vim +++ b/vim/.vim/after/ftplugin/python.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use my desired ALE fixers for python let b:ale_fixers=[ 'black', 'isort' ] let b:undo_ftplugin.='|unlet b:ale_fixers' diff --git a/vim/.vim/after/ftplugin/qf.vim b/vim/.vim/after/ftplugin/qf.vim index 4947593..a4cf9a6 100644 --- a/vim/.vim/after/ftplugin/qf.vim +++ b/vim/.vim/after/ftplugin/qf.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use h/l to go to the previous/next non-empty quickfix or location list nnoremap h :call quickfixed#older() let b:undo_ftplugin.='|nunmap h' diff --git a/vim/.vim/after/ftplugin/rust.vim b/vim/.vim/after/ftplugin/rust.vim index a178d87..35472f6 100644 --- a/vim/.vim/after/ftplugin/rust.vim +++ b/vim/.vim/after/ftplugin/rust.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Check tests too let b:ale_rust_cargo_check_tests=1 let b:undo_ftplugin='|unlet b:ale_rust_cargo_check_tests' diff --git a/vim/.vim/after/ftplugin/sh.vim b/vim/.vim/after/ftplugin/sh.vim index e038c78..4cd9e82 100644 --- a/vim/.vim/after/ftplugin/sh.vim +++ b/vim/.vim/after/ftplugin/sh.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use shfmt as ALE fixer for sh let b:ale_fixers=[ 'shfmt' ] let b:undo_ftplugin.='|unlet b:ale_fixers' diff --git a/vim/.vim/after/ftplugin/zsh.vim b/vim/.vim/after/ftplugin/zsh.vim index 7cc0b5f..f0f811f 100644 --- a/vim/.vim/after/ftplugin/zsh.vim +++ b/vim/.vim/after/ftplugin/zsh.vim @@ -1,3 +1,7 @@ +if !exists("b:undo_ftplugin") + let b:undo_ftplugin='' +endif + " Use shfmt as ALE fixer for zsh let b:ale_fixers=[ 'shfmt' ] let b:undo_ftplugin.='|unlet b:ale_fixers'