Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fugitive#repo().git_command() removed #142

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions plugin/gitv.vim
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand All @@ -252,7 +252,7 @@ endfu "}}}
fu! s:RunCommandRelativeToGitRepo(command) abort "{{{
" Runs the command verbatim but first changing to the root git dir.
" Input commands should include a --git-dir argument to git (see
" fugitive#repo().git_command()).
" FugitiveShellCommand()).
let workingDir = fugitive#repo().tree()

let cd = exists('*haslocaldir') && haslocaldir() ? 'lcd ' : 'cd '
Expand Down Expand Up @@ -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 "
Expand Down Expand Up @@ -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'
Expand Down