diff options
-rwxr-xr-x | bin/thomas | 14 |
1 files changed, 8 insertions, 6 deletions
@@ -1,5 +1,8 @@ #!/bin/bash +FILE=$1 +OUTPUT_FOLDER=output + install_mo() { local confirm if ! command -v "bin/mo" 2>&1 > /dev/null; then @@ -16,13 +19,12 @@ install_mo() { fi } -FILE=$1 -OUTPUT_FOLDER=output - -mkdir -p $OUTPUT_FOLDER +build(){ + mkdir -p $OUTPUT_FOLDER + source thomas.env && cat templates/$1 | bin/mo > $OUTPUT_FOLDER/$FILE +} install_mo - -source thomas.env && cat templates/$1 | bin/mo > $OUTPUT_FOLDER/$FILE +build echo $OUTPUT_FOLDER/$FILE |