diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2018-06-06 19:39:43 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2018-06-06 19:39:43 +1200 |
commit | 641d96aa678bfe74646a7b1ebe50066a2aaf26c0 (patch) | |
tree | a0fe0775c54bfcd4867c8f03b23ee09d89ee252d /vim/ftplugin/markdown.vim | |
parent | Correct ksh pattern (diff) | |
download | dotfiles-641d96aa678bfe74646a7b1ebe50066a2aaf26c0.tar.gz dotfiles-641d96aa678bfe74646a7b1ebe50066a2aaf26c0.zip |
Check for 'formatlistpat' option existence
Diffstat (limited to 'vim/ftplugin/markdown.vim')
-rw-r--r-- | vim/ftplugin/markdown.vim | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/vim/ftplugin/markdown.vim b/vim/ftplugin/markdown.vim index 2bd27d14..94f49c9b 100644 --- a/vim/ftplugin/markdown.vim +++ b/vim/ftplugin/markdown.vim @@ -26,9 +26,11 @@ setlocal formatoptions+=tcqln setlocal formatoptions-=ro " Set list format patterns -let &l:formatlistpat = '^\s*\d\+\.\s\+\' - \ .'\|^[-*+]\s\+\' - \ .'\|^\[^\ze[^\]]\+\]:' +if exists('+option-name') + let &l:formatlistpat = '^\s*\d\+\.\s\+\' + \ .'\|^[-*+]\s\+\' + \ .'\|^\[^\ze[^\]]\+\]:' +endif " Define how to undo this plugin's settings let b:undo_ftplugin = 'setlocal comments<' |