From be1ea053f9911668612a2ef3682dcc54f8fd89b2 Mon Sep 17 00:00:00 2001 From: LiZhenCheng9527 Date: Tue, 30 Dec 2025 11:17:33 +0800 Subject: [PATCH 1/2] versioning Signed-off-by: LiZhenCheng9527 --- .github/workflows/versioning.yml | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/.github/workflows/versioning.yml b/.github/workflows/versioning.yml index bfa4809..7cd39ab 100644 --- a/.github/workflows/versioning.yml +++ b/.github/workflows/versioning.yml @@ -32,19 +32,13 @@ jobs: - name: Run Docusaurus versioning run: npx docusaurus docs:version ${{ steps.extract_version.outputs.version }} - - name: Create branch and commit changes - run: | - git config --global user.name "GitHub Actions" - git config --global user.email "actions@github.com" - BRANCH="version-${{ steps.extract_version.outputs.version }}" - git checkout -b $BRANCH - git add . - git commit -m "Add Docusaurus version ${{ steps.extract_version.outputs.version }}" || echo "No changes to commit" - git push origin $BRANCH - - - name: Create Pull Request - env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - BRANCH="version-${{ steps.extract_version.outputs.version }}" - gh pr create --base main --head $BRANCH --title "Add version ${{ steps.extract_version.outputs.version }}" --body "Automated versioning changes for v${{ steps.extract_version.outputs.version }}. This includes English docs; Chinese will fallback to English as per Docusaurus behavior." + - name: Create Pull Request via API + uses: peter-evans/create-pull-request@v6 + with: + token: ${{ secrets.GITHUB_TOKEN }} + commit-message: "Add Docusaurus version ${{ steps.extract_version.outputs.version }}" + title: "Add version ${{ steps.extract_version.outputs.version }}" + body: "Automated versioning changes for v${{ steps.extract_version.outputs.version }}" + branch: "version-${{ steps.extract_version.outputs.version }}" + base: "main" + delete-branch: true From 924b5252ed00e0d3f867e0d9da060f7dc57f75c5 Mon Sep 17 00:00:00 2001 From: LiZhenCheng9527 Date: Tue, 30 Dec 2025 14:15:06 +0800 Subject: [PATCH 2/2] Duplicate workflows have been removed. Signed-off-by: LiZhenCheng9527 --- .github/workflows/codespell.yml | 21 --------------------- .github/workflows/versioning.yml | 1 + 2 files changed, 1 insertion(+), 21 deletions(-) delete mode 100644 .github/workflows/codespell.yml diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml deleted file mode 100644 index b80fef7..0000000 --- a/.github/workflows/codespell.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Codespell - -on: - push: - branches: [main] - pull_request: - branches: [main] - -permissions: - contents: read - -jobs: - codespell: - name: Check for spelling errors - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Codespell - uses: codespell-project/actions-codespell@v2 diff --git a/.github/workflows/versioning.yml b/.github/workflows/versioning.yml index 7cd39ab..b3c97d0 100644 --- a/.github/workflows/versioning.yml +++ b/.github/workflows/versioning.yml @@ -42,3 +42,4 @@ jobs: branch: "version-${{ steps.extract_version.outputs.version }}" base: "main" delete-branch: true + signoff: true