[issue245] deprecate "update -m" in favour of "merge"?

Dan Christensen jdc at uwo.ca
Mon May 15 09:09:53 CDT 2006


Thomas Arendsen Hein <mercurial-bugs at selenic.com> writes:

> New submission from Thomas Arendsen Hein <thomas at intevation.de>:
>
> Sébastien Pierre asked wether to deprecate 'hg update -m', bos agreed.
> I can live with that, too, as I already started to type 'hg merge' myself.

I've wanted this logical separation between update and merge for a
while.  

With this done, I wonder if it would be better for 'hg update -r REV'
to *not* complain if REV isn't linearly related to the current
version, since the user is simply asking for a certain revision to be
checked out, without the implication of merging.

As far I understand, there is currently no easy way for the user to
say "check out revision REV, whether or not it is linearly related to
the current version, but DO warn me if I have modifications in my
working directory".

Also, when "update -m" is removed, we won't need the -f option for
update, so I would argue that -C should be replaced with -f.  Then
the pattern is quite nice:

hg update -r REV     Checkout the specified revision, warning if there
                     are changes to the working directory.
hg update -r REV -f  Checkout the specified revision, period.
hg merge  -r REV     Merge with specified revision, warning if there
                     are changes to the working directory.
hg merge  -r REV -f  Merge with specified revision, period.

(Of course, "update -C" could temporarily remain an alias for "update
-f".)

Dan

PS: I'm not registered with the issue tracker; not sure if this will
get filed there automatically...



More information about the Mercurial mailing list