[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7v4o37qhi6.fsf@alter.siamese.dyndns.org>
Date: Thu, 30 Jun 2011 11:52:17 -0700
From: Junio C Hamano <gitster@...ox.com>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>,
Stephen Rothwell <sfr@...b.auug.org.au>,
James Morris <jmorris@...ei.org>, linux-next@...r.kernel.org,
linux-kernel@...r.kernel.org, git@...r.kernel.org,
Jeff King <peff@...f.net>
Subject: Re: linux-next: manual merge of the security-testing tree with the
tree
Linus Torvalds <torvalds@...ux-foundation.org> writes:
> It would be lovely if "git show" (and log operations) had some option
> to do a "expensive merge check" and did actually figure out the common
> ancestor and at least took that into account.
>
> It would be doable to do it at least better than we do now - the
> common ancestor is not cheap to compute, but it's much cheaper than a
> full merge, and would at least allow us to flag dangerous merges. Of
> course, it gets fun when there are multiple common ancestors and
> renames. It's entirely possible that it's never going to be practical
> to do anything but "re-do the merge and compare result".
I would have to say that it would boil down to "re-do the merge" whichever
way we implement it, and it is not necessarily a bad thing.
There are ideas to implement a mode of "git merge" that works entirely
in-core without touching the working tree (it may have to write temporary
blobs and possibly trees to the object store, though). It would let sites
like github to let its users accept a trivial pull request that can merge
cleanly on site in the browser without necessarily having to have a local
checkout used for conflict resolution.
If such an "in-core merge" feature is implemented cleanly in a reusable
way, it would be just the matter of comparing the output from it with the
actual committed result.
Of course, if the committed result was deliberately made by "-s ours",
comparison between an auto-merge result and the committed result would
produce a lot of noise, but that is really the point of "expensie merge
check", so the noise in that scenario is a feature, not a bug.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists