summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorAlexis Hildebrandt <afh@surryhill.net>2014-04-27 10:00:04 +0200
committerAlexis Hildebrandt <afh@surryhill.net>2014-04-27 10:00:04 +0200
commit10359fd7014e5d33fdc6ee7cba6d98b10054cecc (patch)
treebdc6ac8e4cf3c00b7dbb59fb99e86610178470dd /tools
parent62bdb2f13a31449ca6f439ee121162647c39855e (diff)
downloadfork-ledger-10359fd7014e5d33fdc6ee7cba6d98b10054cecc.tar.gz
fork-ledger-10359fd7014e5d33fdc6ee7cba6d98b10054cecc.tar.bz2
fork-ledger-10359fd7014e5d33fdc6ee7cba6d98b10054cecc.zip
gendocs: add option to choose pdf papersize
The default will be US Letter [ci skip]
Diffstat (limited to 'tools')
-rwxr-xr-xtools/gendocs.sh16
1 files changed, 15 insertions, 1 deletions
diff --git a/tools/gendocs.sh b/tools/gendocs.sh
index 9126a406..3d082024 100755
--- a/tools/gendocs.sh
+++ b/tools/gendocs.sh
@@ -1,5 +1,19 @@
#!/bin/bash
+
+# By default US Letter is used as the PDF papersize.
+# For those preferring other dimensions add a4 or small
+# as a commandline argument to this script to create a
+# DIN A4 or smallbook version of the PDF.
+case $1 in
+ a4*|afour*)
+ papersize='--texinfo=@afourpaper';;
+ small*)
+ papersize='--texinfo=@smallbook';;
+ *)
+ papersize='';; # US Letter is texinfo default
+esac
+
echo "===================================== Making Info..."
makeinfo ledger3.texi
echo "===================================== Making PDF..."
-texi2pdf --quiet --batch ledger3.texi
+texi2pdf --quiet --batch ${papersize} ledger3.texi