Skip to content

Commit

Permalink
update version tag to 0.0.2
Browse files Browse the repository at this point in the history
  • Loading branch information
msprijatelj committed May 19, 2023
1 parent 42ac7ba commit 8431ebb
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions create_tag.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#!/usr/bin/env bash

set -e

tagName=$1;

if [[ -z "${tagName}" ]]; then
exit 1
fi

update_version () {
local jsonFile=$1
node > out_${jsonFile} <<EOF
var data = require('./${jsonFile}');
data.version = '${tagName}';
console.log(JSON.stringify(data, null, 2));
EOF
rm ${jsonFile}
mv out_${jsonFile} ${jsonFile}
}

update_version package.json
cd lib/
update_version lcp_manifest.json
cd ../

git add package.json lib/lcp_manifest.json
git commit -m "update version tag to ${tagName}"

read -p "Enter tag message: " msg
git tag -s "${tagName}" -m "${msg}"
git push origin
git push origin "${tagName}"

0 comments on commit 8431ebb

Please sign in to comment.