You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
629 B
31 lines
629 B
set -e
|
|
echo "Enter release version: "
|
|
read VERSION
|
|
echo "Enter commit message: "
|
|
read MESSAGE
|
|
|
|
read -p "Releasing $VERSION - are you sure? (y/n)" -n 1 -r
|
|
echo # (optional) move to a new line
|
|
if [[ $REPLY =~ ^[Yy]$ ]]; then
|
|
echo "Releasing $VERSION ..."
|
|
|
|
npm run build
|
|
npm run build-lib
|
|
|
|
git add .
|
|
git commit -m "$MESSAGE"
|
|
git push origin develop
|
|
|
|
npm version $VERSION --message "build: $VERSION"
|
|
# commit
|
|
git checkout master
|
|
git merge develop
|
|
git push origin master
|
|
|
|
# publish
|
|
git tag $VERSION -m "release: $VERSION"
|
|
git push origin "$VERSION"
|
|
|
|
git checkout develop
|
|
fi
|