diff options
author | LordMcFungus <mceagle117@gmail.com> | 2021-03-22 18:05:11 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-22 18:05:11 +0100 |
commit | 76d2d77ddb2bed6b7c6b8ec56648d85da4103ab7 (patch) | |
tree | 11b2d41955ee4bfa0ae5873307c143f6b4d55d26 /vorlesungen/setup | |
parent | more chapter structure (diff) | |
parent | add title image (diff) | |
download | SeminarMatrizen-76d2d77ddb2bed6b7c6b8ec56648d85da4103ab7.tar.gz SeminarMatrizen-76d2d77ddb2bed6b7c6b8ec56648d85da4103ab7.zip |
Merge pull request #1 from AndreasFMueller/master
update
Diffstat (limited to 'vorlesungen/setup')
-rw-r--r-- | vorlesungen/setup | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/vorlesungen/setup b/vorlesungen/setup new file mode 100644 index 0000000..a6f5539 --- /dev/null +++ b/vorlesungen/setup @@ -0,0 +1,35 @@ +#! /bin/bash +# +# setup -- prepare a new topic +# +if [ $# -lt 2 ] +then + echo "not enough arguments" + echo "usage: setup number topic" + echo "Files will be in <number>_<topic>, <topic>-handout, MathSem-<number>-<topic>.tex" + exit 1 +fi + +topic=${2} +number=`printf %02d ${1}` +directory=${number}_${topic} + +if [ -d ${directory} ] +then + echo ${directory} already exists + exit 1 +fi + +mkdir ${directory} + +cp 00_template/common.tex ${directory} +cp 00_template/slides.tex ${directory} + +sed -e "s/xxx/${topic}/g" -e "s/yyy/${number}/g" 00_template/Makefile \ + > ${directory}/Makefile +sed -e "s/xxx/${topic}/g" -e "s/yyy/${number}/g" 00_template/handout.tex \ + > ${directory}/${topic}-handout.tex +sed -e "s/xxx/${topic}/g" -e "s/yyy/${number}/g" 00_template/presentation.tex \ + > ${directory}/MathSem-${number}-${topic}.tex + + |