move vars generation to its script
This commit is contained in:
parent
684fdc516b
commit
720154293a
@ -141,7 +141,7 @@ version.inc.tex: Makefile $(shell git rev-parse --git-dir 2>/dev/null)
|
||||
TZ=UTC date '+\gdef\VCDescribe{%F ($(REF))}%' > $@
|
||||
|
||||
vars.inc.tex: vars.awk wm.sql Makefile
|
||||
./$< wm.sql > $@
|
||||
awk -f $< wm.sql
|
||||
|
||||
slides-2021-03-29.pdf: slides-2021-03-29.txt
|
||||
pandoc -t beamer -i $< -o $@
|
||||
|
11
IV/vars.awk
Executable file → Normal file
11
IV/vars.awk
Executable file → Normal file
@ -1,20 +1,19 @@
|
||||
#!/usr/bin/awk -f
|
||||
|
||||
BEGIN {
|
||||
FS="[() ]"
|
||||
}
|
||||
BEGIN { FS="[() ]" }
|
||||
|
||||
/small_angle constant real default radians/ {
|
||||
if(d) {
|
||||
exit 1
|
||||
} else {
|
||||
printf ("\\newcommand{\\smallAngle}{\\frac{\\pi}{%d}}\n",180/$8);
|
||||
d=1
|
||||
d = sprintf("\\newcommand{\\smallAngle}{\\frac{\\pi}{%d}}\n",180/$8);
|
||||
}
|
||||
}
|
||||
|
||||
END{
|
||||
if(!d){
|
||||
if(d) {
|
||||
print d > "vars.inc.tex"
|
||||
} else {
|
||||
exit 1
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user