找出正确的源分支并且添加skip ci

This commit is contained in:
2026-01-14 03:37:37 +00:00
parent b7a73c4b15
commit c5591f8936

View File

@@ -24,6 +24,7 @@ jobs:
uses: actions/checkout@v4 uses: actions/checkout@v4
with: with:
fetch-depth: 0 fetch-depth: 0
ref: ${{ github.head_ref }}
- name: 配置 Git - name: 配置 Git
run: | run: |
@@ -69,7 +70,7 @@ jobs:
git config user.name "github-actions" git config user.name "github-actions"
git config user.email "github-actions@github.com" git config user.email "github-actions@github.com"
git add package.json git add package.json
git commit -m "chore: bump version to $NEW_VERSION" git commit -m "chore: bump version to $NEW_VERSION [skip ci]"
# 推送到当前分支 # 推送到当前分支
BRANCH_NAME=$(git rev-parse --abbrev-ref HEAD) BRANCH_NAME=$(git rev-parse --abbrev-ref HEAD)