clone ups default branch --- bug or feature?

Dmitriy Morozov hg at foxcub.org
Mon Mar 31 10:40:32 CDT 2008


Hm, let's see. I have a master clone (with default branch being the
main one), and I have the dev clone (with dev branch being the main
one). Most of the time I clone from the development branch (to add a
feature). Unfortunately, after clone I still need to do one more
operation (hg up tip) to get the correct state. Of course, the problem
repeats when I want to add a named feature to an already named
feature. This seems rather counter-intuitive to me. Perhaps, I'm
thinking of the whole thing wrong. What's the right work flow with
named branches?

Thanks.
Dmitriy

On Mon, Mar 31, 2008 at 11:31 AM, Matt Mackall <mpm at selenic.com> wrote:
>
>
>  On Mon, 2008-03-31 at 05:33 -0400, Dmitriy Morozov wrote:
>  > "hg clone" implicitly executes "up default" instead of "up tip". Is
>  > this the intended behavior? In my work flow it causes periodic
>  > annoyances (I usually expect a fresh clone to be at tip only to
>  > discover that it's at default branch, and I forgot to do "hg up tip"),
>  > so I was wondering if this was overlooked, or if there is a setting
>  > where this is the preferred behavior.
>
>  It is intended: it's the -default- branch. Think of it as MAIN or TRUNK
>  or whatever. If you've named your main branch something other than
>  default, well...
>
>  --
>  Mathematics is the supreme nostalgia of our time.
>
>


More information about the Mercurial mailing list