Re: [PATCH 0/3] Teach Git about the patience diff algorithm
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 7, 2009, 20:48 UTC
- Message-ID
- <7v63kqall2.fsf@gitster.siamese.dyndns.org>
- In-Reply-To
- <alpine.DEB.1.00.0901072121260.7496@intel-tinevez-2-302>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
Show 21 quoted lines
> After compiling and installing, something like this should be fun to > watch: > > $ git rev-list --all --parents | \ > grep " .* " | \ > while read commit parent1 parent2 otherparents > do > test -z "$otherparents" || continue > git checkout $parent1 && > git merge $parent2 && > git diff > without-patience.txt && > ... > if ! cmp without-patience.txt with-patience.txt > then > echo '===============================' > echo "differences found in merge $commit" > ... > cat with-patience.txt > fi || > exit > done | tee patience-merge.out
An even more interesting test would be possible by dropping "&&" from the two "git merge" invocations.
- Your sample will exit at the first conflicting merge otherwise.
- You may find cases where one resolves cleanly while the other leaves conflicts.