##// END OF EJS Templates
bookmarks: update only proper bookmarks on push -r/-B (issue 3973)...
Wojciech Lopata -
r19515:14c91b18 stable
parent child Browse files
Show More
@@ -1951,6 +1951,9 b' class localrepository(object):'
1951 1951
1952 1952 self.ui.debug("checking for updated bookmarks\n")
1953 1953 rb = remote.listkeys('bookmarks')
1954 revnums = map(unfi.changelog.rev, revs or [])
1955 ancestors = [
1956 a for a in unfi.changelog.ancestors(revnums, inclusive=True)]
1954 1957 for k in rb.keys():
1955 1958 if k in unfi._bookmarks:
1956 1959 nr, nl = rb[k], hex(self._bookmarks[k])
@@ -1958,6 +1961,8 b' class localrepository(object):'
1958 1961 cr = unfi[nr]
1959 1962 cl = unfi[nl]
1960 1963 if bookmarks.validdest(unfi, cr, cl):
1964 if ancestors and cl.rev() not in ancestors:
1965 continue
1961 1966 r = remote.pushkey('bookmarks', k, nr, nl)
1962 1967 if r:
1963 1968 self.ui.status(_("updating bookmark %s\n") % k)
@@ -422,7 +422,6 b' of this test.'
422 422 remote: adding manifests
423 423 remote: adding file changes
424 424 remote: added 1 changesets with 1 changes to 1 files
425 updating bookmark @ failed!
426 425 exporting bookmark add-foo
427 426
428 427 $ cd ..
General Comments 0
You need to be logged in to leave comments. Login now