Use diff-tree -p instead of "git diff" in git-export.
PATCH 1/1 Use diff-tree -p instead of "git diff" in git-export.
Now diff-tree can produce patch itself, there is no reason to depend on Cogito to show diff in the git-export output anymore.
Signed-off-by Junio C Hamano <[email protected]>
---
This is a reworked patch---we just made -p to imply recursive so we can just say diff-tree -p, not diff-tree -p -r like I said in the previous patch.
git-export.c | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
git-export.c +1 -1
@@ -18,7 +18,7 @@ void show_commit(struct commit *commit)char *against =sha1_to_hex (commit->parents->item->object.sha1);printf ("\n\n======== diff against %s ========\n" , against);fflush (NULL ); -sprintf (cmdline,"git diff -r %s:%s" , against, hex); +sprintf (cmdline,"diff-tree -p %s %s" , against, hex);system (cmdline); }printf ("======== end ========\n\n" );