How do I use vim as 'git show' editor?

前端 未结 5 1628
深忆病人
深忆病人 2021-02-08 12:50

all as described in How do I use vim as 'git log' editor? doesn\'t work for git show . I use often

git show HEAD

ctrl+z 

ps 

  PID TTY          TIME CM         


        
5条回答
  •  清酒与你
    2021-02-08 13:31

    can simply use git show bf9f84042 | vim - in edit mod, or git show bf9f84042 | vim -R - in read only mod, without changing gitconfig

    or

    git config --global diff.tool vimdiff using vimdiff as diff.tool, and then git difftool bf9f042 232wf2f to diff

提交回复
热议问题