#!/bin/sh clean() { ## Not sure if this step is needed, guess latexmk should be able to detect a change printf "\t¤ Clean previous build" find latex/$1/build -mindepth 1 -prune -exec rm -rf {} \; ## HTML exports #printf ' - possible HTML export' #find latex/$1 -type d -name 'html*' -exec rm -r {} \; echo } build() { printf "\t¤ Generation of the PDF format\n" latexmk $opts -outdir=../build -cd ./latex/$1/main/$1_manual 1> /dev/null [ -f ./latex/$1/build/$1_manual.pdf ] && mv ./latex/$1/build/$1_manual.pdf . # cd - > /dev/null echo }