Swoft 核心和扩展组件的版本发布工具.
- 同步最新改动到各个子仓库
- 批量的发布新版本
Github https://github.com/swoftlabs/swoft-releasecli
工具预览:
环境依赖:
- git
- php
- swoole
- composer
curl https://raw.githubusercontent.com/swoftlabs/swoft-releasecli/master/install.sh | bash
内容来自于 install.sh 脚本
cd ~
git clone https://github.com/swoftlabs/swoft-releasecli .swoft-releasecli
cd .swoft-releasecli
composer install
ln -s $PWD/bin/releasecli /usr/local/bin/releasecli
chmod a+x bin/releasecli
先用git拉取最新的 swoft-components 或 swoft-ext 到本地,跳转到仓库目录,执行:
# 1. add remote for all components
releasecli git:addrmt --all
# 2. force push all change to every github repo
releasecli git:fpush --all
# 3. release new version for all components
releasecli git:release --all -y -t v2.0.8
Use builtin command
releasecli upself
cd ~/swoft-releasecli
git pull
chmod a+x bin/releasecli
Required the
swoftcli
php -d phar.readonly=0 ~/.composer/vendor/bin/swoftcli phar:pack -o=releasecli.phar
rm -f /usr/local/bin/releasecli
rm -rf ~/swoft-releasecli