问题
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:
Trygit 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