changeset 13662:80d6e1f63ed9

localrepo: do not update bookmarks in addchangegroup We want to update the current bookmark to the most recent revision on current branch unless there is a remote bookmark that points to a different descendant. Addchangegroup is called before we can check for remote bookmarks. We don't update the bookmark in addchangegroup anymore to allow proper updating of bookmarks in pull.
author David Soria Parra <dsp@php.net>
date Mon, 14 Mar 2011 20:53:55 +0100
parents ee349e228835
children d16c99f16f00
files mercurial/localrepo.py tests/test-bookmarks-pushpull.t
diffstat 2 files changed, 1 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/localrepo.py	Tue Mar 15 18:33:36 2011 +0100
+++ b/mercurial/localrepo.py	Mon Mar 14 20:53:55 2011 +0100
@@ -1894,10 +1894,6 @@
                 self.hook("incoming", node=hex(cl.node(i)),
                           source=srctype, url=url)
 
-        # FIXME - why does this care about tip?
-        if newheads == oldheads:
-            bookmarks.update(self, self.dirstate.parents(), self['tip'].node())
-
         # never return 0 here:
         if newheads < oldheads:
             return newheads - oldheads - 1
--- a/tests/test-bookmarks-pushpull.t	Tue Mar 15 18:33:36 2011 +0100
+++ b/tests/test-bookmarks-pushpull.t	Mon Mar 14 20:53:55 2011 +0100
@@ -26,6 +26,7 @@
   adding manifests
   adding file changes
   added 1 changesets with 1 changes to 1 files
+  updating bookmark Y
   (run 'hg update' to get a working copy)
   $ hg bookmarks
      Y                         0:4e3505fd9583