junegunn / gv.vim

A git commit browser in Vim
1.35k stars 54 forks source link

Diff command/pager settings #86

Open B4rc1 opened 3 years ago

B4rc1 commented 3 years ago

Is there any way to change the way diffs are displayed? I already google around and searched the issues of this repo but found nothing. I have delta setup in my .gitconifg like so:

[core]
  pager = delta

Is there any way to change the gv.vim diffs to also use delta as a pager?

This screenshot sums my problem up pretty well: Left is gv.vim diffing the last commit and to the right is the output of git diff HEAD~1 which does the same.

gv vim_vs_pager

princejoogie commented 1 year ago

any update on this issue or if its feasible?

junegunn commented 1 year ago

What you're seeing is a fugitive buffer, not a terminal output. Since modern versions of Vim have built-in terminal emulator, we can use it to show the terminal output of git show OBJECT instead of relying on fugitive. But then we lose the ability to navigate the objects using fugitive maps (:help fugitive-navigation-maps) which I find invaluable.