summaryrefslogtreecommitdiff
path: root/ausbutler-single.sh
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2020-10-08 23:58:30 +0200
committeremkael <emkael@tlen.pl>2020-10-08 23:58:30 +0200
commit9a0ca4d1075f879b812cd8a1b55ab3a2c8e07c40 (patch)
treec3d885017b3e35aea1583c7ac2d5b6f4095f924c /ausbutler-single.sh
parent22d81d669191f669edd609d94859a8e480fa5b00 (diff)
Multiple configs handling rewritten to use envsubst
Diffstat (limited to 'ausbutler-single.sh')
-rwxr-xr-xausbutler-single.sh10
1 files changed, 9 insertions, 1 deletions
diff --git a/ausbutler-single.sh b/ausbutler-single.sh
index 322c9ab..2f95c68 100755
--- a/ausbutler-single.sh
+++ b/ausbutler-single.sh
@@ -5,7 +5,15 @@ cd "$(dirname "$0")"
echo "Processing $TOURNAMENT..."
-ln -sfn configs/config.$TOURNAMENT config
+set -o allexport
+source configs/_common.env
+source configs/$TOURNAMENT.env
+set +o allexport
+
+ls config.template | while read CONFIGFILE
+do
+ envsubst < config.template/$CONFIGFILE > config/$CONFIGFILE
+done
python jfrteamy-ausbutler/butler.py calculate generate nowait
echo "Done"