Khaelid Khaelid - 5 months ago 34
Git Question

Using custom diff tool with `git show`

With git I can set a custom diff tool that is used for certain file extensions by the following in


[diff "csv_diff"]
command = Tools/csv_diff

and this in
(in the root of the repository)

*.csv diff=csv_diff

This works when using
git diff
, but it doesn't work with
git show
. My question is, how do I use a custom tool with
git show


Looks like you're looking for the --ext-diff option.

Here's what git show docs say about it:


Allow an external diff helper to be executed. If you set an external diff driver with gitattributes, you need to use this option with git-log and friends.