mirror of
https://github.com/APIParkLab/APIPark.git
synced 2026-06-14 20:41:15 +08:00
test
This commit is contained in:
Executable → Regular
-7
@@ -4,7 +4,6 @@
|
||||
BRANCH=$(git rev-parse --abbrev-ref HEAD)
|
||||
|
||||
# 如果是从 feature 分支推送
|
||||
echo $BRANCH
|
||||
if [[ $BRANCH == feature/* || $BRANCH == fix/* ]]; then
|
||||
# 获取远程仓库列表
|
||||
REMOTES=$(git remote)
|
||||
@@ -14,10 +13,4 @@ if [[ $BRANCH == feature/* || $BRANCH == fix/* ]]; then
|
||||
echo "Pushing $BRANCH to GitLab..."
|
||||
git push gitlab $BRANCH
|
||||
fi
|
||||
|
||||
# 只有在明确要求时才推送到 GitHub
|
||||
if echo "$REMOTES" | grep -q "github"; then
|
||||
echo "Pushing $BRANCH to GitHub..."
|
||||
git push github $BRANCH
|
||||
fi
|
||||
fi
|
||||
Reference in New Issue
Block a user