This repository has been archived on 2022-08-19. You can view files and clone it, but cannot push or open issues or pull requests.
hydrogen-web/scripts/release.sh

15 lines
396 B
Bash
Raw Permalink Normal View History

2020-03-21 16:02:37 +05:30
if [ -z "$1" ]; then
echo "provide a new version, current version is $(jq '.version' package.json)"
exit 1
fi
VERSION=$1
git checkout master
git pull --rebase origin master
jq ".version = \"$VERSION\"" package.json > package.json.tmp
rm package.json
mv package.json.tmp package.json
git add package.json
git commit -m "release v$VERSION"
git tag "v$VERSION"
git push --tags origin master