blob: a0abefc0b480f8613bc0881d22906fb6e0babdd5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/usr/bin/env bash
TEMPLATE_FILE="app/js/generated/hbs/templates.js"
COMMITISH=$(git rev-parse --short HEAD)
COMMITDATE=$(git show -s --format=%cd)
perl -pi -e "s/UNKNOWN_VERSION/$COMMITISH/" $TEMPLATE_FILE
perl -pi -e "s/COMMIT_DATE/$COMMITDATE/" $TEMPLATE_FILE
if [ ! -f "$TEMPLATE_FILE" ] ; then
echo "file $TEMPLATE_FILE not found" 1>&2
exit 1
fi
exit 0
|