295 for b in pushop.ui.configlist('bookmarks', 'pushing')] |
295 for b in pushop.ui.configlist('bookmarks', 'pushing')] |
296 |
296 |
297 for bm in localbookmarks: |
297 for bm in localbookmarks: |
298 rnode = remotebookmarks.get(bm) |
298 rnode = remotebookmarks.get(bm) |
299 if rnode and rnode in repo: |
299 if rnode and rnode in repo: |
300 lctx, rctx = repo[bm], repo[rnode] |
300 lctx, rctx = localbookmarks.changectx(bm), repo[rnode] |
301 if bookmarks.validdest(repo, rctx, lctx): |
301 if bookmarks.validdest(repo, rctx, lctx): |
302 bookmarkedheads.add(lctx.node()) |
302 bookmarkedheads.add(lctx.node()) |
303 else: |
303 else: |
304 if bm in newbookmarks and bm not in remotebookmarks: |
304 if bm in newbookmarks and bm not in remotebookmarks: |
305 bookmarkedheads.add(repo[bm].node()) |
305 bookmarkedheads.add(localbookmarks[bm]) |
306 |
306 |
307 return bookmarkedheads |
307 return bookmarkedheads |
308 |
308 |
309 def checkheads(pushop): |
309 def checkheads(pushop): |
310 """Check that a push won't add any outgoing head |
310 """Check that a push won't add any outgoing head |