diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2019-05-07 12:22:48 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2019-05-07 12:51:56 +0300 |
commit | 216b2d199bdf3730243795ff71515e636184d98f (patch) | |
tree | 2cc5900030a3a02805e312b711c55e7c3f652311 /doc/cli.sh | |
parent | 3ac33926fb98740d7da4bb33961dea9b68a5d19c (diff) |
Convert UTF-8 tree characters to ASCII when producing PS from XHTML in doc/cli.sh
Diffstat (limited to 'doc/cli.sh')
-rwxr-xr-x | doc/cli.sh | 15 |
1 files changed, 13 insertions, 2 deletions
@@ -73,6 +73,17 @@ done # Manual. # +function xhtml_to_ps () # <from> <to> [<html2ps-options>] +{ + local from="$1" + shift + local to="$1" + shift + + sed -e 's/├/|/g' -e 's/│/|/g' -e 's/─/-/g' -e 's/└/`/g' "$from" | \ + html2ps "${@}" -o "$to" +} + cli -I .. \ -v version="$(echo "$version" | sed -e 's/^\([^.]*\.[^.]*\).*/\1/')" \ -v date="$date" \ @@ -83,8 +94,8 @@ cli -I .. \ --link-regex '%b(#.+)?%../../build2/doc/build2-build-system-manual.xhtml$1%' \ --output-prefix build2-package-manager- manual.cli -html2ps -f doc.html2ps:a4.html2ps -o build2-package-manager-manual-a4.ps build2-package-manager-manual.xhtml +xhtml_to_ps build2-package-manager-manual.xhtml build2-package-manager-manual-a4.ps -f doc.html2ps:a4.html2ps ps2pdf14 -sPAPERSIZE=a4 -dOptimize=true -dEmbedAllFonts=true build2-package-manager-manual-a4.ps build2-package-manager-manual-a4.pdf -html2ps -f doc.html2ps:letter.html2ps -o build2-package-manager-manual-letter.ps build2-package-manager-manual.xhtml +xhtml_to_ps build2-package-manager-manual.xhtml build2-package-manager-manual-letter.ps -f doc.html2ps:letter.html2ps ps2pdf14 -sPAPERSIZE=letter -dOptimize=true -dEmbedAllFonts=true build2-package-manager-manual-letter.ps build2-package-manager-manual-letter.pdf |