From ea38c7d6640a1f8b037288f0bf7aa8c2f3678a0b Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Wed, 27 Jun 2018 20:31:35 -0400 Subject: [PATCH] Don't include newline in Git version --- autoload/fugitive.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index d834a06..9d759c7 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -91,7 +91,7 @@ endfunction function! fugitive#GitVersion(...) abort if !has_key(s:git_versions, g:fugitive_git_executable) - let s:git_versions[g:fugitive_git_executable] = matchstr(system(g:fugitive_git_executable.' --version'), "\\S\\+\n") + let s:git_versions[g:fugitive_git_executable] = matchstr(system(g:fugitive_git_executable.' --version'), "\\S\\+\\ze\n") endif return s:git_versions[g:fugitive_git_executable] endfunction