Set git diff to a default value

柔情痞子 提交于 2019-12-03 02:42:30

问题


I previously changed my git diff tool with git config --global diff.external <diff-tool-name>. I decided I don't like that tool and wanted to switch back.

I tried meddling around and did something like: git config --global diff.external git-diff. Now calling git diff to see unstaged changes yields:

fatal: ambiguous argument '48e66b706d21398f28240810e7fc0d44d8f92d99': unknown revision or path not in the working tr
Use '--' to separate paths from revisions
external diff died, stopping at somefile.ext.

How do I set my git diff command to use the default command line git diff that came with git. Something like:

git config --global diff.

and then what?


回答1:


Try
git config --global --unset diff

and

git config --global --unset diff.external

See the explanation of git config for further details.



来源:https://stackoverflow.com/questions/4955752/set-git-diff-to-a-default-value

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!