From 24c68a685262d4d7aeabf574b6f77acb74f14ddc Mon Sep 17 00:00:00 2001 From: marty Date: Tue, 30 Nov 2010 10:21:32 +1300 Subject: [PATCH] complain if the user doesnt have filetype plugins enabled --- plugin/NERD_commenter.vim | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugin/NERD_commenter.vim b/plugin/NERD_commenter.vim index ce39eb5..aa84478 100644 --- a/plugin/NERD_commenter.vim +++ b/plugin/NERD_commenter.vim @@ -1001,6 +1001,10 @@ function! NERDComment(isVisual, type) range let oldIgnoreCase = &ignorecase set noignorecase + if !exists("g:did_load_ftplugin") || g:did_load_ftplugin != 1 + call s:NerdEcho("filetype plugins should be enabled. See :help NERDComInstallation and :help :filetype-plugin-on", 0) + endif + if a:isVisual let firstLine = line("'<") let lastLine = line("'>")