Prioritize our own tags

This commit is contained in:
Tim Pope 2011-08-11 11:03:18 -04:00
parent 8548a9c621
commit 7991e832a3

View File

@ -148,10 +148,10 @@ function! s:Detect(path)
call buffer.setvar('&path',s:sub(buffer.getvar('&path'),'^\.%(,|$)','')) call buffer.setvar('&path',s:sub(buffer.getvar('&path'),'^\.%(,|$)',''))
endif endif
if b:git_dir !~# ',' && stridx(buffer.getvar('&tags'),b:git_dir.'/tags') == -1 if b:git_dir !~# ',' && stridx(buffer.getvar('&tags'),b:git_dir.'/tags') == -1
call buffer.setvar('&tags',b:git_dir.'/tags'.','.buffer.getvar('&tags'))
if &filetype != '' if &filetype != ''
call buffer.setvar('&tags',buffer.getvar('&tags').','.b:git_dir.'/'.&filetype.'.tags') call buffer.setvar('&tags',b:git_dir.'/'.&filetype.'.tags'.','.buffer.getvar('&tags'))
endif endif
call buffer.setvar('&tags',buffer.getvar('&tags').','.b:git_dir.'/tags')
endif endif
endif endif
endfunction endfunction