commit 1de4a240c6af1276f3193d3e6af0fe9b85555e37
parent 2448433f83ee651b6c0df2d7e1c6a2c10d5bd20f
Author: Alex Balgavy <a.balgavy@gmail.com>
Date: Mon, 10 Feb 2020 12:52:04 +0100
vim: dynamically set tags file
Former-commit-id: f15391216f3378c2abf8afdd8de1c5d4cf50076b
Diffstat:
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/vim/vimrc b/vim/vimrc
@@ -395,7 +395,17 @@ else
endif
" where to find tags files
-set tags=./tags,tags,.git/tags
+set tags=./tags;~,tags,~/.tags
+if has("path_extra")
+ " If compiled with path_extra, search for .git/tags upwards in the tree
+ " and stop searching at $HOME
+ let &tags = &tags.',.git/tags;~'
+else
+ let &tags = &tags.',.git/tags'
+endif
+
+" follow the 'ignorecase' option when looking for tags
+set tagcase=followic
" dictionary file
set dictionary=/usr/share/dict/words