Using bookmarks in Mercurial itself

Sune Foldager cryo at cyanite.org
Mon Jun 20 11:34:38 UTC 2011


On 2011-06-19 19:19, Martin Geisler wrote:
>Peter Arrenbrecht <peter.arrenbrecht at gmail.com> writes:
>
>> On Fri, Jun 17, 2011 at 3:36 PM, Martin Geisler <mg at aragost.com> wrote:
>>> Patrick Mézard <pmezard at gmail.com> writes:
>>>
>>>> Le 17/06/11 13:08, Martin Geisler a écrit :
>>>>>
>>>>> It's of course just a gut feeling, but I feel that a DVCS should
>>>>> allow us to commit and experiment more freely than we do today.
>>>>
>>>> Mercurial is a DVCS, not your everyday project library or web
>>>> framework. If broken stuff is pushed,
>>>
>>> I did not talk about pushing broken stuff, I talked about pushing stuff
>>> where the test suite still passes.
>>>
>>>> I lose data because I run tip.
>>>
>>> If bookmarked branches are even slightly useful, then it should be
>>> possible to have them in a repository while also have a stable default
>>> branch tip. But you're right that
>>>
>>>  hg update stable
>>>  hg update default
>>>
>>> might take you back to a "random" head on the default branch, including
>>> a head on an experimental branch. That does sound dangerous -- would a
>>> "crew" bookmark on the right default head solve this?
>>
>> Bookmarks on anonymous branches which live in a named branch "crew" or
>> "features"?
>
>Yeah, that is a possibility! Right now switching branches only "works"
>because both of our branches have a single head -- if a branch has more
>than one head, 'hg update branch' becomes scary.

As another curious thing, the prepush logic spends a lot of code on getting the
multi-head-per-branch cases right, but they are hardly ever used in practice :-p.

-Sune



More information about the Mercurial-devel mailing list