Gentoo Archives: gentoo-pms

From: David Leverton <levertond@××××××××××.com>
To: gentoo-pms@l.g.o
Cc: David Leverton <levertond@××××××××××.com>
Subject: [gentoo-pms] [PATCH 2/2] Update TeX4ht sed hacks
Date: Thu, 16 Apr 2009 19:37:33
Message-Id: 1239910647-11276-2-git-send-email-levertond@googlemail.com
In Reply to: [gentoo-pms] [PATCH 1/2] Work around TeX4ht being weird by David Leverton
1 Account for slightly different whitespace in the output of newer
2 versions, the possibility of tables in appendices, and the silly
3 locale-dependent behaviour of sed.
4 ---
5 Makefile | 6 +++---
6 1 files changed, 3 insertions(+), 3 deletions(-)
7
8 diff --git a/Makefile b/Makefile
9 index 27d58c1..a9f1108 100644
10 --- a/Makefile
11 +++ b/Makefile
12 @@ -21,12 +21,12 @@ pms.html: $(SOURCEFILES) pms.bbl
13 xhlatex pms
14 @# work around irregularity in how links to longtables are
15 @# formatted in the List of Tables
16 - sed -i -e '/<span class="lotToc" >&#x00A0;/{N;N;s/\(&#x00A0;<a \nhref="[^"]\+">\)\([0-9.]\+\)\n/\2\1/}' pms.html
17 + LC_ALL=C sed -i -e '/<span class="lotToc" >&#x00A0;/{N;N;s/\(&#x00A0;<a \nhref="[^"]\+">\)\([0-9A-Z.]\+\)[ \n]/\2\1/}' pms.html
18 @# indent algorithms properly, and avoid adding extra vertical
19 @# space in Konqueror
20 - sed -i -e 's/span style="width:/span style="display:-moz-inline-box;display:inline-block;height:1px;width:/' pms.html
21 + LC_ALL=C sed -i -e 's/span style="width:/span style="display:-moz-inline-box;display:inline-block;height:1px;width:/' pms.html
22 @# align algorithm line numbers properly
23 - sed -i -e '/<span class="ALCitem">/{N;s/\n\(class="[^"]\+">\)\([0-9]:\)<\/span>/\1\&#x2007;\2/}' pms.html
24 + LC_ALL=C sed -i -e '/<span class="ALCitem">/{N;s/\n\(class="[^"]\+">\)\([0-9]:\)<\/span>/\1\&#x2007;\2/}' pms.html
25
26 pms.bbl: pms.bib pms.tex vc.tex eapi-cheatsheet.pdf
27 latex pms
28 --
29 1.6.2.3

Replies

Subject Author
Re: [gentoo-pms] [PATCH 2/2] Update TeX4ht sed hacks Ciaran McCreesh <ciaran.mccreesh@××××××××××.com>
Re: [gentoo-pms] [PATCH 2/2] Update TeX4ht sed hacks Yannick Mortier <mvmortier@××××××××××.com>