changeset 166:1fe62e7f1fae

Don't trigger a tags generation for the empty startup buffer.
author Ludovic Chabant <ludovic@chabant.com>
date Sat, 18 Feb 2017 21:45:39 -0800
parents cbc1ebe23ef1
children 34c57ad6eb45
files autoload/gutentags.vim
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/autoload/gutentags.vim	Sat Feb 18 18:21:35 2017 -0800
+++ b/autoload/gutentags.vim	Sat Feb 18 21:45:39 2017 -0800
@@ -198,7 +198,9 @@
     " Don't setup gutentags for anything that's not a normal buffer
     " (so don't do anything for help buffers and quickfix windows and
     "  other such things)
-    if &buftype != ''
+    " Also don't do anything for the default `[No Name]` buffer you get
+    " after starting Vim.
+    if &buftype != '' || bufname('%') == ''
         return
     endif