Commits

Junio C Hamano  committed 4daf6fc Merge

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

  • Participants
  • Parent commits 87cb3b8, 701825d
  • Branches maint

Comments (0)

Files changed (1)

File builtin/add.c

 
 	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);