diff mercurial/commands.py @ 477:520540fd6b64

Handle errors in .hgtags or hgrc [tags] section more gracefully. -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Handle errors in .hgtags or hgrc [tags] section more gracefully. manifest hash: 85c62e1bf3ad78b243ee60f43c3c577700a8c96d -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFCvp6jW7P1GVgWeRoRAo23AKCZRU22IweynNtf9k3q4pEyqEaozACeMIRV 6tNOkr3h6jTiMZ2bJgPeabg= =+U5s -----END PGP SIGNATURE-----
author Thomas Arendsen Hein <thomas@intevation.de>
date Sun, 26 Jun 2005 13:25:07 +0100
parents 0ab093b473c5
children 7293cb91bf2a
line wrap: on
line diff
--- a/mercurial/commands.py	Sun Jun 26 12:04:59 2005 +0100
+++ b/mercurial/commands.py	Sun Jun 26 13:25:07 2005 +0100
@@ -662,15 +662,15 @@
 
 def tags(ui, repo):
     """list repository tags"""
-    
+
     l = repo.tagslist()
     l.reverse()
-    for t,n in l:
+    for t, n in l:
         try:
-            r = repo.changelog.rev(n)
+            r = "%5d:%s" % (repo.changelog.rev(n), hg.hex(n))
         except KeyError:
-            r = "?"
-        print "%-30s %5d:%s" % (t, repo.changelog.rev(n), hg.hex(n))
+            r = "    ?:?"
+        ui.write("%-30s %s\n" % (t, r))
 
 def tip(ui, repo):
     """show the tip revision"""