aboutsummaryrefslogtreecommitdiff
path: root/vim/after/ftplugin/markdown.vim
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-07-08 21:05:11 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-07-08 21:05:11 +1200
commited11c7e686c9c856da25d73d236d9c3798b94bc2 (patch)
tree9219af4626c2785ffec9ce1a2a970aa1a61522dd /vim/after/ftplugin/markdown.vim
parente3d1467a0c4bb10effd012e87f53a8c93a17ee60 (diff)
downloaddotfiles-ed11c7e686c9c856da25d73d236d9c3798b94bc2.tar.gz
dotfiles-ed11c7e686c9c856da25d73d236d9c3798b94bc2.zip
Test 'modifiable' for spellchecking text/markdown
Diffstat (limited to 'vim/after/ftplugin/markdown.vim')
-rw-r--r--vim/after/ftplugin/markdown.vim2
1 files changed, 1 insertions, 1 deletions
diff --git a/vim/after/ftplugin/markdown.vim b/vim/after/ftplugin/markdown.vim
index 7ec37c64..69b794dd 100644
--- a/vim/after/ftplugin/markdown.vim
+++ b/vim/after/ftplugin/markdown.vim
@@ -13,7 +13,7 @@ let b:undo_ftplugin = b:undo_ftplugin
\ . '|unlet b:did_ftplugin_after'
" Spellcheck documents we're actually editing (not just viewing)
-if !&readonly
+if &modifiable && !&readonly
setlocal spell
let b:undo_ftplugin = b:undo_ftplugin
\ . '|setlocal spell<'