mirror of
https://github.com/facebook/sapling.git
synced 2024-12-29 08:02:24 +03:00
Add debughash and debugindex commands
This commit is contained in:
parent
de51831199
commit
b9dbea8b13
14
hg
14
hg
@ -211,6 +211,20 @@ elif cmd == "dumpmanifest":
|
||||
for f in files:
|
||||
print hg.hex(m[f]), f
|
||||
|
||||
elif cmd == "debughash":
|
||||
f = repo.file(args[0])
|
||||
print f.encodepath(args[0])
|
||||
|
||||
elif cmd == "debugindex":
|
||||
r = hg.revlog(open, args[0], "")
|
||||
print " rev offset length base linkrev"+\
|
||||
" p1 p2 nodeid"
|
||||
for i in range(r.count()):
|
||||
e = r.index[i]
|
||||
print "% 6d % 9d % 7d % 5d % 7d %s.. %s.. %s.." % (
|
||||
i, e[0], e[1], e[2], e[3],
|
||||
hg.hex(e[4][:5]), hg.hex(e[5][:5]), hg.hex(e[6][:5]))
|
||||
|
||||
elif cmd == "merge":
|
||||
if args:
|
||||
other = hg.repository(ui, args[0])
|
||||
|
Loading…
Reference in New Issue
Block a user