On Tue, Mar 8, 2011 at 9:49 PM, Junio C Hamano <gitster@xxxxxxxxx> wrote: > Mart Sõmermaa <mrts.pydev@xxxxxxxxx> writes: > >> On Tue, Mar 1, 2011 at 2:11 AM, Junio C Hamano <gitster@xxxxxxxxx> wrote: >>> In any case, a minimum patch to give what Mart wanted to see would >>> probably look like this. I'll leave bugfixes, documentation and tests to >>> the readers ;-). >> >> The minimum looks to be the optimum -- IMHO this is entirely sufficient, > > I suspect not, as I don't think I ever did anything to the codepath for -B > output, and I also recall spending some time thinking about this issue in > an earlier message that I mentioned -B besides "deletion", none of the > suggestions in which I don't think I tried to implement. Your suggestion is as follows: "It also might make sense to apply the similar principle to shorten the output with -B when a rewrite patch is expressed as a single hunk patch that removes everything old and then adds everthing new." I have to admit that I've never used -B, only -M, so please don't mind that its semantics and exact behavior are a bit foreign to me. After running t/t4130-apply-criss-cross-rename.sh, `git diff -M -B` outputs the following: diff --git a/file2 b/file1 similarity index 100% rename from file2 rename to file1 diff --git a/file1 b/file2 similarity index 100% rename from file1 rename to file2 Can you bring a similar example of changes in the output after the above-mentioned similar principle has been implemented for -B? > I also vaguely recall that I suspected that the output may not have the > usual "index deadbeaf..000000 mode" line and that I chose to ignore it. 'deadbeaf' is present: $ ../git/bin-wrappers/git diff -D HEAD diff --git a/foo.txt b/foo.txt deleted file mode 100644 index 257cc56..0000000 Can we perhaps consider the -B behavior orthogonal to -D (unless I am missing something very important here)? Best regards, MS -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html