#!/bin/bash set -e echo "Building Isabelle snippets" # Avoid conflict with possible user settings export ISABELLE_IDENTIFIER=IsabelleDissBreitner export AFP=$PWD/isa isabelle build -v -b -c -d . Snippets ghc --make -O extractisa.hs ./extractisa echo "Building Isabelle theory representation" isabelle build -v -b -c -d . Formalization mkdir -p isa-html rsync -ra ~/.isabelle/$ISABELLE_IDENTIFIER/browser_info/Unsorted/Formalization/ isa-html/ chmod a+r isa-html/session_graph.pdf # shrug echo "Buiding listings" make -C listings echo "Buiding benchmark table" (cd benchmarks/; ./gen-table.sh) echo "Buiding dlist table" (cd code/dlist; ./gen-table.sh) echo "Building dissertation" pdflatex diss.tex makeindex -o diss.ind diss.idx biber diss pdflatex diss.tex makeindex -o diss.ind diss.idx pdflatex diss.tex echo "Cleanup" rm -f diss.{aux,bbl,blg,idx,log,out,ptb,thm,toc,ilg,ind,bcf,run.xml} rm -f ./*.hi ./*.o rm -f code/dlist/*.hi rm -f code/dlist/*.o rm -rf isa-thy-output/empty rm -f isa-thy-output/empty.pdf rm -f code/dlist/CsvToTex rm -f extractisa cp README.html README.html-orig sed '/PIWIK START/,/PIWIK END/d' README.html-orig > README.html tar --verbose --create --gzip --file diss-release.tar.gz --exclude=README.html-orig --exclude=diss-release.tar.gz * mv README.html-orig README.html