##// END OF EJS Templates
debugbuilddag: lock repo before starting transaction
Mads Kiilerich -
r15875:7eca9db6 default
parent child Browse files
Show More
@@ -1368,8 +1368,10 b' def debugbuilddag(ui, repo, text=None,'
1368
1368
1369 tags = []
1369 tags = []
1370
1370
1371 tr = repo.transaction("builddag")
1371 lock = tr = None
1372 try:
1372 try:
1373 lock = repo.lock()
1374 tr = repo.transaction("builddag")
1373
1375
1374 at = -1
1376 at = -1
1375 atbranch = 'default'
1377 atbranch = 'default'
@@ -1445,12 +1447,12 b' def debugbuilddag(ui, repo, text=None,'
1445 atbranch = data
1447 atbranch = data
1446 ui.progress(_('building'), id, unit=_('revisions'), total=total)
1448 ui.progress(_('building'), id, unit=_('revisions'), total=total)
1447 tr.close()
1449 tr.close()
1450
1451 if tags:
1452 repo.opener.write("localtags", "".join(tags))
1448 finally:
1453 finally:
1449 ui.progress(_('building'), None)
1454 ui.progress(_('building'), None)
1450 tr.release()
1455 release(tr, lock)
1451
1452 if tags:
1453 repo.opener.write("localtags", "".join(tags))
1454
1456
1455 @command('debugbundle', [('a', 'all', None, _('show all details'))], _('FILE'))
1457 @command('debugbundle', [('a', 'all', None, _('show all details'))], _('FILE'))
1456 def debugbundle(ui, bundlepath, all=None, **opts):
1458 def debugbundle(ui, bundlepath, all=None, **opts):
General Comments 0
You need to be logged in to leave comments. Login now