comparison mercurial/commands.py @ 687:44b30755d07c

Hide file hashes in log There are six different kinds of revision numbers and hashes: changeset hash and local number manifest hash and local number file hash and local number We really ought to expose only the changeset hash and local number, so begin hiding the others from the end user manifest hash: 40d07cc930e84a9283d5e03ade23e3454401e148
author Matt Mackall <mpm@selenic.com>
date Tue, 12 Jul 2005 20:55:42 -0800
parents 0cfc5966b2c2
children 4315db147f00
comparison
equal deleted inserted replaced
686:d7d68d27ebe5 687:44b30755d07c
181 for parent in log.parents(node) 181 for parent in log.parents(node)
182 if ui.debugflag or parent != hg.nullid] 182 if ui.debugflag or parent != hg.nullid]
183 if not ui.debugflag and len(parents) == 1 and parents[0][0] == rev-1: 183 if not ui.debugflag and len(parents) == 1 and parents[0][0] == rev-1:
184 parents = [] 184 parents = []
185 185
186 ui.write("changeset: %d:%s\n" % (changerev, hg.hex(changenode)))
187 for tag in repo.nodetags(changenode):
188 ui.status("tag: %s\n" % tag)
189 for parent in parents:
190 ui.write("parent: %d:%s\n" % parent)
186 if filelog: 191 if filelog:
187 ui.write("revision: %d:%s\n" % (filerev, hg.hex(filenode))) 192 ui.debug("file rev: %d:%s\n" % (filerev, hg.hex(filenode)))
188 for parent in parents: 193 ui.note("manifest: %d:%s\n" % (repo.manifest.rev(changes[0]),
189 ui.write("parent: %d:%s\n" % parent) 194 hg.hex(changes[0])))
190 ui.status("changeset: %d:%s\n" % (changerev, hg.hex(changenode)))
191 else:
192 ui.write("changeset: %d:%s\n" % (changerev, hg.hex(changenode)))
193 for tag in repo.nodetags(changenode):
194 ui.status("tag: %s\n" % tag)
195 for parent in parents:
196 ui.write("parent: %d:%s\n" % parent)
197 ui.note("manifest: %d:%s\n" % (repo.manifest.rev(changes[0]),
198 hg.hex(changes[0])))
199 ui.status("user: %s\n" % changes[1]) 195 ui.status("user: %s\n" % changes[1])
200 ui.status("date: %s\n" % time.asctime( 196 ui.status("date: %s\n" % time.asctime(
201 time.localtime(float(changes[2].split(' ')[0])))) 197 time.localtime(float(changes[2].split(' ')[0]))))
202 if ui.debugflag: 198 if ui.debugflag:
203 files = repo.changes(changelog.parents(changenode)[0], changenode) 199 files = repo.changes(changelog.parents(changenode)[0], changenode)