mercurial/commands.py
changeset 2854 cdbca3d59518
parent 2835 2ff57e3113a4
parent 2852 046a8b03ea59
child 2857 c9b08cacf983
equal deleted inserted replaced
2841:619f1c65384c 2854:cdbca3d59518
  1331         rev = repo.changelog.tip()
  1331         rev = repo.changelog.tip()
  1332     else:
  1332     else:
  1333         rev = repo.lookup(rev)
  1333         rev = repo.lookup(rev)
  1334     change = repo.changelog.read(rev)
  1334     change = repo.changelog.read(rev)
  1335     n = change[0]
  1335     n = change[0]
  1336     files = repo.manifest.readflags(n)
  1336     files = repo.manifest.read(n)
  1337     wlock = repo.wlock()
  1337     wlock = repo.wlock()
  1338     repo.dirstate.rebuild(rev, files.iteritems())
  1338     repo.dirstate.rebuild(rev, files)
  1339 
  1339 
  1340 def debugcheckstate(ui, repo):
  1340 def debugcheckstate(ui, repo):
  1341     """validate the correctness of the current dirstate"""
  1341     """validate the correctness of the current dirstate"""
  1342     parent1, parent2 = repo.dirstate.parents()
  1342     parent1, parent2 = repo.dirstate.parents()
  1343     repo.dirstate.read()
  1343     repo.dirstate.read()
  2144         except hg.RepoError:
  2144         except hg.RepoError:
  2145             n = repo.manifest.lookup(rev)
  2145             n = repo.manifest.lookup(rev)
  2146     else:
  2146     else:
  2147         n = repo.manifest.tip()
  2147         n = repo.manifest.tip()
  2148     m = repo.manifest.read(n)
  2148     m = repo.manifest.read(n)
  2149     mf = repo.manifest.readflags(n)
       
  2150     files = m.keys()
  2149     files = m.keys()
  2151     files.sort()
  2150     files.sort()
  2152 
  2151 
  2153     for f in files:
  2152     for f in files:
  2154         ui.write("%40s %3s %s\n" % (hex(m[f]), mf[f] and "755" or "644", f))
  2153         ui.write("%40s %3s %s\n" % (hex(m[f]),
       
  2154                                     m.execf(f) and "755" or "644", f))
  2155 
  2155 
  2156 def merge(ui, repo, node=None, force=None, branch=None):
  2156 def merge(ui, repo, node=None, force=None, branch=None):
  2157     """Merge working directory with another revision
  2157     """Merge working directory with another revision
  2158 
  2158 
  2159     Merge the contents of the current working directory and the
  2159     Merge the contents of the current working directory and the