| 1 |
#!/bin/bash |
| 2 |
|
| 3 |
NAME=beamerappendixnote |
| 4 |
TEXMF_DIR=~/texmf/tex/latex/$NAME |
| 5 |
BUILD_DIR=.tex-build |
| 6 |
|
| 7 |
# compile sty |
| 8 |
mkdir -p $BUILD_DIR |
| 9 |
tex -output-directory=$BUILD_DIR $NAME.ins |
| 10 |
|
| 11 |
# install sty |
| 12 |
mkdir -p $TEXMF_DIR |
| 13 |
ln -sf "`pwd`/$BUILD_DIR/$NAME.sty" $TEXMF_DIR |
| 14 |
|
| 15 |
# compile examples |
| 16 |
for f in example*.tex |
| 17 |
do xelatex -output-directory=$BUILD_DIR $f |
| 18 |
done |
| 19 |
xelatex -output-directory=$BUILD_DIR example*.tex |
| 20 |
ln -sf $BUILD_DIR/example*.pdf ./ |
| 21 |
|
| 22 |
# compile documentation |
| 23 |
xelatex -output-directory=$BUILD_DIR $NAME.dtx |
| 24 |
xelatex -output-directory=$BUILD_DIR $NAME.dtx |
| 25 |
ln -sf $BUILD_DIR/$NAME.pdf |
| 26 |
|
| 27 |
# zip for upload |
| 28 |
cd .. |
| 29 |
rm -f zip $NAME.zip |
| 30 |
zip $NAME.zip $NAME/* |