diff mercurial/commands.py @ 350:b4e0e20646bb

Merge with TAH -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Merge with TAH manifest hash: ec82cc2d7b7357fd7db4917e09d7d6865482de58 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFCr+f1ywK+sNU5EO8RAuPtAJ0WilDBo3iG4S/dmIabhzYW987TtgCgkjkM 8OmatsrjG01iJAhkKJj+XnQ= =mOLr -----END PGP SIGNATURE-----
author mpm@selenic.com
date Wed, 15 Jun 2005 00:33:57 -0800
parents d7df759d0e97 b2293093b89e
children dda243bb34b3
line wrap: on
line diff
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -81,8 +81,8 @@ def show_changeset(ui, repo, rev=0, chan
         changerev = filelog.linkrev(filenode)
         changenode = changenode or changelog.node(changerev)
     else:
+        log = changelog
         changerev = rev
-        log = changelog
         if changenode is None:
             changenode = changelog.node(changerev)
         elif not changerev:
@@ -94,7 +94,6 @@ def show_changeset(ui, repo, rev=0, chan
         return
 
     changes = changelog.read(changenode)
-    description = changes[4].strip().splitlines()
 
     parents = [(log.rev(parent), hg.hex(parent))
                for parent in log.parents(node)
@@ -117,13 +116,14 @@ def show_changeset(ui, repo, rev=0, chan
     ui.status("date:        %s\n" % time.asctime(
         time.localtime(float(changes[2].split(' ')[0]))))
     ui.note("files:       %s\n" % " ".join(changes[3]))
+    description = changes[4].strip()
     if description:
         if ui.verbose:
             ui.status("description:\n")
-            ui.status(changes[4].strip())
-            ui.status("\n")
+            ui.status(description)
+            ui.status("\n\n")
         else:
-            ui.status("summary:     %s\n" % description[0])
+            ui.status("summary:     %s\n" % description.splitlines()[0])
     ui.status("\n")
 
 def help(ui, cmd=None):