diff options
author | Guangxiong Lin <[email protected]> | 2024-03-01 20:01:01 +0800 |
---|---|---|
committer | Guangxiong Lin <[email protected]> | 2024-03-01 20:01:01 +0800 |
commit | cf1b8d1b947f1213ce02bb8fcf04001509aab68b (patch) | |
tree | 3e29d63e31d3efb6b7159f690d34bd2b885dfd82 | |
parent | b9390cbb0c013a67bc2f962c52e66cddd1c1874d (diff) | |
download | dotfiles-cf1b8d1b947f1213ce02bb8fcf04001509aab68b.tar.gz dotfiles-cf1b8d1b947f1213ce02bb8fcf04001509aab68b.tar.bz2 dotfiles-cf1b8d1b947f1213ce02bb8fcf04001509aab68b.zip |
Use relative path when using git diff
-rw-r--r-- | .vim/after/plugin/fzf.vim | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/.vim/after/plugin/fzf.vim b/.vim/after/plugin/fzf.vim index 4812000..5b23416 100644 --- a/.vim/after/plugin/fzf.vim +++ b/.vim/after/plugin/fzf.vim @@ -32,7 +32,10 @@ function! s:fzf_qf_sink(line) abort endfunction let s:command_git_main_branch = 'git symbolic-ref --short refs/remotes/origin/HEAD' -let s:command_git_patch_files_changed = 'git diff --name-only --merge-base $(' +let s:command_git_patch_files_changed = 'git diff' + \ . ' --name-only' + \ . ' --relative' + \ . ' --merge-base $(' \ . s:command_git_main_branch . ')' command! FzfQuickFix call fzf#run({ |