mercurial/localrepo.py
changeset 23749 a387b0390082
parent 23714 e3a0e7e21f54
child 23775 885c0290f7d5
equal deleted inserted replaced
23748:4ab66de46a96 23749:a387b0390082
  1430                 # check in files
  1430                 # check in files
  1431                 added = []
  1431                 added = []
  1432                 changed = []
  1432                 changed = []
  1433                 removed = list(ctx.removed())
  1433                 removed = list(ctx.removed())
  1434                 linkrev = len(self)
  1434                 linkrev = len(self)
       
  1435                 self.ui.note(_("committing files:\n"))
  1435                 for f in sorted(ctx.modified() + ctx.added()):
  1436                 for f in sorted(ctx.modified() + ctx.added()):
  1436                     self.ui.note(f + "\n")
  1437                     self.ui.note(f + "\n")
  1437                     try:
  1438                     try:
  1438                         fctx = ctx[f]
  1439                         fctx = ctx[f]
  1439                         if fctx is None:
  1440                         if fctx is None:
  1451                         if error or errcode and errcode != errno.ENOENT:
  1452                         if error or errcode and errcode != errno.ENOENT:
  1452                             self.ui.warn(_("trouble committing %s!\n") % f)
  1453                             self.ui.warn(_("trouble committing %s!\n") % f)
  1453                         raise
  1454                         raise
  1454 
  1455 
  1455                 # update manifest
  1456                 # update manifest
       
  1457                 self.ui.note(_("committing manifest\n"))
  1456                 removed = [f for f in sorted(removed) if f in m1 or f in m2]
  1458                 removed = [f for f in sorted(removed) if f in m1 or f in m2]
  1457                 drop = [f for f in removed if f in m]
  1459                 drop = [f for f in removed if f in m]
  1458                 for f in drop:
  1460                 for f in drop:
  1459                     del m[f]
  1461                     del m[f]
  1460                 mn = self.manifest.add(m, trp, linkrev,
  1462                 mn = self.manifest.add(m, trp, linkrev,
  1464             else:
  1466             else:
  1465                 mn = p1.manifestnode()
  1467                 mn = p1.manifestnode()
  1466                 files = []
  1468                 files = []
  1467 
  1469 
  1468             # update changelog
  1470             # update changelog
       
  1471             self.ui.note(_("committing changelog\n"))
  1469             self.changelog.delayupdate(tr)
  1472             self.changelog.delayupdate(tr)
  1470             n = self.changelog.add(mn, files, ctx.description(),
  1473             n = self.changelog.add(mn, files, ctx.description(),
  1471                                    trp, p1.node(), p2.node(),
  1474                                    trp, p1.node(), p2.node(),
  1472                                    user, ctx.date(), ctx.extra().copy())
  1475                                    user, ctx.date(), ctx.extra().copy())
  1473             p = lambda: tr.writepending() and self.root or ""
  1476             p = lambda: tr.writepending() and self.root or ""