Mercurial > hg
comparison hgext/convert/hg.py @ 33487:a050d37c2c70
bookmark: use 'applychanges' in the convert extension
author | Boris Feld <boris.feld@octobus.net> |
---|---|
date | Mon, 10 Jul 2017 17:30:20 +0200 |
parents | b1bc8cf3fea8 |
children | 5b8cb63c130c |
comparison
equal
deleted
inserted
replaced
33486:af402f11cb9d | 33487:a050d37c2c70 |
---|---|
423 wlock = self.repo.wlock() | 423 wlock = self.repo.wlock() |
424 lock = self.repo.lock() | 424 lock = self.repo.lock() |
425 tr = self.repo.transaction('bookmark') | 425 tr = self.repo.transaction('bookmark') |
426 self.ui.status(_("updating bookmarks\n")) | 426 self.ui.status(_("updating bookmarks\n")) |
427 destmarks = self.repo._bookmarks | 427 destmarks = self.repo._bookmarks |
428 for bookmark in updatedbookmark: | 428 changes = [(bookmark, nodemod.bin(updatedbookmark[bookmark])) |
429 destmarks[bookmark] = nodemod.bin(updatedbookmark[bookmark]) | 429 for bookmark in updatedbookmark] |
430 destmarks.recordchange(tr) | 430 destmarks.applychanges(self.repo, tr, changes) |
431 tr.close() | 431 tr.close() |
432 finally: | 432 finally: |
433 lockmod.release(lock, wlock, tr) | 433 lockmod.release(lock, wlock, tr) |
434 | 434 |
435 def hascommitfrommap(self, rev): | 435 def hascommitfrommap(self, rev): |