mercurial/localrepo.py
changeset 18394 5010448197bc
parent 18382 f3b21beb9802
child 18395 904b7109938e
equal deleted inserted replaced
18393:a38039ef7312 18394:5010448197bc
  1365                 # be compliant anyway
  1365                 # be compliant anyway
  1366                 #
  1366                 #
  1367                 # if minimal phase was 0 we don't need to retract anything
  1367                 # if minimal phase was 0 we don't need to retract anything
  1368                 phases.retractboundary(self, targetphase, [n])
  1368                 phases.retractboundary(self, targetphase, [n])
  1369             tr.close()
  1369             tr.close()
  1370             branchmap.updatecache(self)
  1370             branchmap.updatecache(self.filtered('served'))
  1371             return n
  1371             return n
  1372         finally:
  1372         finally:
  1373             if tr:
  1373             if tr:
  1374                 tr.release()
  1374                 tr.release()
  1375             lock.release()
  1375             lock.release()
  2386             if changesets > 0:
  2386             if changesets > 0:
  2387                 if srctype != 'strip':
  2387                 if srctype != 'strip':
  2388                     # During strip, branchcache is invalid but coming call to
  2388                     # During strip, branchcache is invalid but coming call to
  2389                     # `destroyed` will repair it.
  2389                     # `destroyed` will repair it.
  2390                     # In other case we can safely update cache on disk.
  2390                     # In other case we can safely update cache on disk.
  2391                     branchmap.updatecache(self)
  2391                     branchmap.updatecache(self.filtered('served'))
  2392                 def runhooks():
  2392                 def runhooks():
  2393                     # forcefully update the on-disk branch cache
  2393                     # forcefully update the on-disk branch cache
  2394                     self.ui.debug("updating the branch cache\n")
  2394                     self.ui.debug("updating the branch cache\n")
  2395                     self.hook("changegroup", node=hex(cl.node(clstart)),
  2395                     self.hook("changegroup", node=hex(cl.node(clstart)),
  2396                               source=srctype, url=url)
  2396                               source=srctype, url=url)