diff options
Diffstat (limited to 'conf/build-magic.sh')
-rwxr-xr-x | conf/build-magic.sh | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/conf/build-magic.sh b/conf/build-magic.sh new file mode 100755 index 00000000..94d1a01f --- /dev/null +++ b/conf/build-magic.sh @@ -0,0 +1,21 @@ +#! /bin/sh + +RSCRIPT="spells-build.sh" + +if [ -a $RSCRIPT ]; then printf ""; else + echo '#! /bin/sh' > $RSCRIPT; + echo 'cat \' >> $RSCRIPT; + chmod a+x $RSCRIPT +fi + +for n in `grep -o '"#..."' magic.conf.template`; do + if grep $n $RSCRIPT; then printf ""; else + CHANGES=1 + echo "|sed 's/${n}/${n}/' \\" >> $RSCRIPT; + fi +done + +if [ x$CHANGES == x1 ] +then echo "spells-build.sh has been updated; please provide invocations for spells and/or teleport anchors."; +else cat magic.conf.template | ./$RSCRIPT > magic.conf; +fi
\ No newline at end of file |