加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
release.sh 678 Bytes
一键复制 编辑 原始数据 按行查看 历史
tommyshao 提交于 2019-01-12 10:24 . chore
git checkout master
git merge dev
#!/usr/bin/env sh
set -e
echo "Enter release version: "
read VERSION
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 version $VERSION --message "[release] $VERSION" --allow-same-version
# lib
VERSION=$VERSION npm run lib
git add -A
git commit -m "[release] $VERSION"
git push origin master
git push origin refs/tags/v$VERSION
if [[ $VERSION =~ "beta" ]]
then
npm publish --tag beta
else
npm publish
fi
git checkout dev
git rebase master
git push origin dev
echo "completed!!!!"
fi
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化