From patchwork Sat Feb 9 13:00:39 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [5,of,6] minirst: HTML formatter tweaks From: Dan Villiom Podlaski Christiansen X-Patchwork-Id: 863 Message-Id: <45b34ea40358b6f8fe14.1360414839@s0-0.paconsult7.bbnplanet.net> To: Mercurial Devel Date: Sat, 09 Feb 2013 13:00:39 +0000 # HG changeset patch # User Dan Villiom Podlaski Christiansen # Date 1360414106 0 # Node ID 45b34ea40358b6f8fe14ef874ebbc5de5556f23c # Parent 675a399c2c9d5c94d4798bc8fd11f855eaff5672 minirst: HTML formatter tweaks - output table rows on distinct lines - don't make the first row a table header diff --git a/mercurial/minirst.py b/mercurial/minirst.py --- a/mercurial/minirst.py +++ b/mercurial/minirst.py @@ -546,11 +546,8 @@ def formathtml(blocks): for row in table: l = [] for v in zip(row): - if not t: - l.append('%s' % v) - else: - l.append('%s' % v) - t.append(' %s\n' % ''.join(l)) + l.append('%s' % v) + t.append(' %s\n' % '\n'.join(l)) out.append('\n%s
\n' % ''.join(t)) elif btype == 'definition': openlist('dl', level) diff --git a/tests/test-minirst.py.out b/tests/test-minirst.py.out --- a/tests/test-minirst.py.out +++ b/tests/test-minirst.py.out @@ -758,9 +758,15 @@ 30 column format: html format: ---------------------------------------------------------------------- - - - + + + + + + + + +
abc
123
foobarbaz this list is very very very long man
abc
123
foobarbaz this list is very very very long man
----------------------------------------------------------------------