From 28afef550371cd506db2045cbdd89d895bec5091 Mon Sep 17 00:00:00 2001 From: Vincent Driessen Date: Thu, 14 Apr 2016 17:31:17 +0200 Subject: Perform diff-tree recursively to have the same output as diff --- git/diff.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'git/diff.py') diff --git a/git/diff.py b/git/diff.py index 7a75ffed..de3aa1e8 100644 --- a/git/diff.py +++ b/git/diff.py @@ -95,9 +95,11 @@ class Diffable(object): if other is self.Index: args.insert(0, '--cached') elif other is NULL_TREE: + args.insert(0, '-r') # recursive diff-tree args.insert(0, '--root') diff_cmd = self.repo.git.diff_tree elif other is not None: + args.insert(0, '-r') # recursive diff-tree args.insert(0, other) diff_cmd = self.repo.git.diff_tree -- cgit v1.2.1