From a50e0725879bb64fb3b10cda71ada043d28afe0b Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Sat, 6 Jul 2019 13:47:30 -0400 Subject: [PATCH] Fix handling of bar in argument parsing --- autoload/fugitive.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index 74b4efb..31e7a70 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -973,7 +973,7 @@ function! s:ExpandSplit(string, ...) abort if handle_bar && string =~# '^\s*|' return [list, substitute(string, '^\s*', '', '')] endif - let arg = matchstr(string, '^\s*\%(' . dquote . '''[^'']*''\|\\.\|\S\)\+') + let arg = matchstr(string, '^\s*\%(' . dquote . '''[^'']*''\|\\.\|[^[:space:] ' . (handle_bar ? '|' : '') . ']\)\+') let string = strpart(string, len(arg)) let arg = substitute(substitute(arg, '^\s\+', '', ''), \ '\(' . dquote . '''\%(''''\|[^'']\)*''\|\\[' . s:fnameescape . ']\|^\\[>+-]\|!\d*\)\|' . s:expand,