cours-m1-eea/compile.sh

17 lines
704 B
Bash
Raw Normal View History

2019-01-09 20:46:09 +01:00
#!/bin/bash
2019-01-06 23:01:51 +01:00
# Pour compiler tous les fichiers sources du dépot:
2019-03-07 14:44:34 +01:00
#find . -name "main.tex" -execdir sh -c "pwd && latexmk -e '$pdflatex=q/pdflatex %O -shell-escape %S/' -pdf {} -quiet| grep Latexmk" \;
# 3 compilation nécessaire pour obtenir un résultat stable
find . -name "main.tex" -execdir sh -c "pwd && pdflatex -shell-escape -interaction=batchmode {} &&pdflatex -shell-escape -interaction=batchmode {}&&pdflatex -shell-escape -interaction=batchmode {}" \;
2019-01-09 20:46:09 +01:00
2019-03-05 15:37:38 +01:00
mkdir "public"
for i in `find . -maxdepth 1 -type d -regex \.\/[0-9].*?`;do
cp $i/Cours/main.pdf ./public/${i:2}.pdf;
done;
2019-01-23 16:20:57 +01:00
#clean up :
2019-01-09 20:46:09 +01:00
shopt -s globstar
2019-03-07 14:44:34 +01:00
rm -f **/*.aux **/*.log **/*.out **/*.fls **/*.fdb_latexmk **/*.toc **/*.pyg