From fa189605f68960a3a34e5ba5653bce9f8f411e54 Mon Sep 17 00:00:00 2001 From: Sankhesh Jhaveri Date: Wed, 29 Sep 2021 11:37:09 -0400 Subject: [PATCH] Support latest fugitive changes NOTE: Does not maintain backwards compatibility with older vim-fugitive releases. --- plugin/gitv.vim | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugin/gitv.vim b/plugin/gitv.vim index 28bcded..4b6d47b 100644 --- a/plugin/gitv.vim +++ b/plugin/gitv.vim @@ -241,7 +241,7 @@ fu! s:RunGitCommand(command, verbatim) "{{{ "switches to the buffer repository before running the command and switches back after. if !a:verbatim "switches to the buffer repository before running the command and switches back after. - let cmd = fugitive#repo().git_command() .' '. a:command + let cmd = FugitiveShellCommand() .' '. a:command let [result, finalCmd] = s:RunCommandRelativeToGitRepo(cmd) else let result = system(a:command) @@ -521,7 +521,7 @@ fu! s:GetFileSlices(range, filePath, commitCount, extraArgs) "{{{ "NOTE: this could get massive for a large repo and large range let range = a:range[0] . ',' . a:range[1] let range = substitute(range, "'", "'\\\\''", 'g') "force unix style escaping even on windows - let git = fugitive#repo().git_command() + let git = FugitiveShellCommand() let sliceCmd = "for hash in `".git." log " . a:extraArgs[0] let sliceCmd .= " --no-color --pretty=format:%H -".a:commitCount." -- " . a:filePath . '`; ' let sliceCmd .= "do " @@ -571,7 +571,7 @@ endfu "}}} fu! s:GetFinalOutputForHashes(hashes) "{{{ if len(a:hashes) > 0 let extraArgs = s:ReapplyReservedArgs(['', '']) - let git = fugitive#repo().git_command() + let git = FugitiveShellCommand() let cmd = 'for hash in ' . join(a:hashes, " ") . '; ' let cmd .= "do " let cmd .= git.' log'