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 a135d1096740e6a4c133be195fd14948128e8d77 (tree)
parent 8bbc4d8816581d57b33364b11115cf64210c69ca
Author: Tim Pope <code@tpope.net>
Date:   Mon,  3 Jun 2019 00:31:46 -0400

Only activate Projectionist if config file exists

References https://github.com/tpope/vim-projectionist/issues/130

Diffstat:
Mplugin/fugitive.vim | 5++++-
1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/plugin/fugitive.vim b/plugin/fugitive.vim @@ -232,7 +232,10 @@ function! s:ProjectionistDetect() abort if exists('+shellslash') && !&shellslash let base = tr(base, '/', '\') endif - call projectionist#append(base, FugitiveCommonDir(dir) . '/info/projections.json') + let file = FugitiveCommonDir(dir) . '/info/projections.json' + if filereadable(file) + call projectionist#append(base, file) + endif endif endfunction