cws/build
author Christian Urban <christian.urban@kcl.ac.uk>
Wed, 09 Nov 2022 16:44:16 +0000
changeset 435 fda7c39f3b6a
parent 427 6e93040e3378
child 459 d59404a41d5f
permissions -rwxr-xr-x
updated wordle testing
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
427
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     1
#!/bin/bash
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     2
set -euo pipefail
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     3
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     4
fls=${1:-"core_cw01.tex core_cw02.tex core_cw03.tex main_cw01.tex main_cw02.tex main_cw03.tex main_cw04.tex main_cw05.tex"} 
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     5
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     6
for f in $fls; do
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     7
    echo -e "making $f"
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     8
    xelatex $f
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
     9
    mv "${f%.tex}.pdf" tmp.pdf
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
    10
    gs -o "${f%.tex}.pdf" -dNoOutputFonts -sDEVICE=pdfwrite tmp.pdf 
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
    11
done    
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
    12
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
    13
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
    14
# prevent PDF from being copied
6e93040e3378 updated
Christian Urban <christian.urban@kcl.ac.uk>
parents:
diff changeset
    15
###  gs -o "${f%.tex}.pdf" -dNoOutputFonts -sDEVICE=pdfwrite tmp.pdf