Skip to content

Commit 48c7c02

Browse files
committed
fix: print error msg when user did not set filetype plugin on in vimrc (fixes #620)
1 parent cde2e2e commit 48c7c02

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

autoload/doge.vim

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,11 @@ endfunction
7676
"
7777
" arg: Either a count (0 by default) or a string (empty by default).
7878
function! doge#generate(arg) abort
79+
if !exists('b:doge_supported_doc_standards')
80+
echoerr "[vim-doge] It seems like you forgot to set `filetype plugin on` in your .vimrc"
81+
return 1
82+
endif
83+
7984
" Immediately validate if the doc standard is allowed.
8085
if index(b:doge_supported_doc_standards, b:doge_doc_standard) < 0
8186
echoerr printf(

0 commit comments

Comments
 (0)