From 8dbbac472ffa0977666ce44c62a2b7a06549f008 Mon Sep 17 00:00:00 2001 From: overdodactyl Date: Tue, 25 Sep 2018 13:33:52 -0600 Subject: [PATCH] add script to automate incrementing updater version number --- scripts/updater_version.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 scripts/updater_version.sh diff --git a/scripts/updater_version.sh b/scripts/updater_version.sh new file mode 100755 index 0000000..000ba00 --- /dev/null +++ b/scripts/updater_version.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +new_version=$1 + +# Substitute version number +current_ver="$(sed 's/[- ]//g' <<< $(sed -n '/CURR_VER/p' website/index.html))" +sed -i -e "s/$current_ver/$new_version/g" website/index.html + +# Build website and push to GitHub +parcel build website/index.html -d website/dist --public-url ./ +git add website/* +git commit -m "website: change updater version number" +git push +git subtree push --prefix website/dist origin gh-pages \ No newline at end of file