pull -u should update when there's nothing to pull

Matt Mackall mpm at selenic.com
Fri Jun 20 15:52:24 CDT 2008

On Fri, 2008-06-20 at 14:32 -0500, Jason Orendorff wrote:
> Currently pull -u doesn't update if there's nothing to pull.

Sigh, old news.

 -u --update     update to new tip if changesets were pulled

> Is there a rationale for the current behavior?  It seems quite strange
> for those two things (whether any changesets were pulled, and whether
> to update) to be connected like that.

Consider these two repos:

server: a-b-c-d
client: a-b-c-d-e-f

If the client assumes "hg pull -u leaves me at the server tip", they're
going to be awfully confused. Changesets e and f have absolutely nothing
to do with the pull action. 

> Mossop: What does |hg parent| say?

This seems to be the Mercurial equivalent of "is it plugged in?"

Mathematics is the supreme nostalgia of our time.

More information about the Mercurial-devel mailing list