aboutsummaryrefslogtreecommitdiff
path: root/builtin/add.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-02-13 11:42:18 -0800
committerJunio C Hamano <gitster@pobox.com>2012-02-13 11:42:18 -0800
commit4daf6fc837f7cc84335958b9d9e8a29e41b4ee8e (patch)
treea6fbd54fee0a3d58d91db28da0fa36b4ebb854d9 /builtin/add.c
parent87cb3b82a42613dc3ffd1eddf95f8c306a045ad1 (diff)
parent701825de23da2bff6c784d33ff27f75e802abd81 (diff)
downloadgit-4daf6fc837f7cc84335958b9d9e8a29e41b4ee8e.tar.gz
git-4daf6fc837f7cc84335958b9d9e8a29e41b4ee8e.tar.xz
Merge branch 'js/add-e-submodule-fix' into maint
* js/add-e-submodule-fix: add -e: do not show difference in a submodule that is merely dirty
Diffstat (limited to 'builtin/add.c')
-rw-r--r--builtin/add.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/builtin/add.c b/builtin/add.c
index 1c42900ff..b79336d71 100644
--- a/builtin/add.c
+++ b/builtin/add.c
@@ -280,6 +280,7 @@ static int edit_patch(int argc, const char **argv, const char *prefix)
argc = setup_revisions(argc, argv, &rev, NULL);
rev.diffopt.output_format = DIFF_FORMAT_PATCH;
+ DIFF_OPT_SET(&rev.diffopt, IGNORE_DIRTY_SUBMODULES);
out = open(file, O_CREAT | O_WRONLY, 0644);
if (out < 0)
die (_("Could not open '%s' for writing."), file);