motiejus/dotfiles

Unnamed repository; edit this file 'description' to name the repository.
git clone https://git.jakstys.lt/motiejus/dotfiles.git
Log | Tree | Refs | README | LICENSE

commit c2569c5de4b0c74a4cab8b8916df74817e2a2cce (tree)
parent e674a7e2f3626ad22178efabd663e004064f951d
Author: Tim Pope <code@tpope.net>
Date:   Fri, 19 Aug 2011 21:15:15 -0400

Support space and comma paths with tags

Diffstat:
Mplugin/fugitive.vim | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/plugin/fugitive.vim b/plugin/fugitive.vim @@ -144,10 +144,10 @@ function! s:Detect(path) if expand('%:p') =~# '//' call buffer.setvar('&path',s:sub(buffer.getvar('&path'),'^\.%(,|$)','')) endif - 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 stridx(buffer.getvar('&tags'),escape(b:git_dir.'/tags',', ')) == -1 + call buffer.setvar('&tags',escape(b:git_dir.'/tags',', ').','.buffer.getvar('&tags')) if &filetype != '' - call buffer.setvar('&tags',b:git_dir.'/'.&filetype.'.tags'.','.buffer.getvar('&tags')) + call buffer.setvar('&tags',escape(b:git_dir.'/'.&filetype.'.tags',', ').','.buffer.getvar('&tags')) endif endif endif