[PATCH] add support for marking changesets as dead

Martin Geisler mg at lazybytes.net
Wed Feb 2 03:35:21 CST 2011


Matt Mackall <mpm at selenic.com> writes:

> On Tue, 2011-02-01 at 21:41 -0200, Wagner Bruna wrote:
>
>> IMHO it'd be far less confusing for new users if changeset metadata
>> were also used for "abandoning" topological heads, since it is very
>> similar in concept (and possibly implementation) to closing named
>> branches (to some extent, closing a named branch and reopening it at
>> another point can be used right now for "abandoned" topological
>> lines).
>
> The similarity between closed and abandoned branches is very
> superficial. Closed branches stay in history; abandoned ones are
> dropped from history, presumably the sooner the better. We should
> probably make an effort to hide abandoned changesets from users while
> they're still present, in which case the only thing storing the marks
> as changesets serves to do is confuse people using older hg with weird
> csets.

Ehm, you say "abandoned ones are dropped from history" and that is not
the case at all. Did you misunderstand the idea of abandoned/dead
changesets?

The main idea is that they do not participate in push/pull unless they
will have an effect on the other repository. Here "effect" means that
they will turn a line of development into an abandoned/dead line.

In other words, if I already have part of a branch that you abandon,
then pulling from you will give me the rest of th branch, including the
changeset that marks it abandoned. If I have no part of your abandoned
branch, then 'hg pull' wont transfer anything -- the abandoned
changesets stay put in your repository and wont spread.

Also, the patch made by Henrik does indeed hide the dead changesets from
commands like 'hg log'.

So I agree with Wagner that the similarity to 'hg commit --close-branch'
is big -- the marker changeset added by --kill is just even stronger: it
says "consider me closed, do not display me in 'hg log' and do not
push/pull me".

-- 
Martin Geisler

Mercurial links: http://mercurial.ch/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20110202/d8de17f7/attachment.pgp>


More information about the Mercurial-devel mailing list