From 5b0a27125c9d6a24ecf3f8131f3ca3ff99d084b6 Mon Sep 17 00:00:00 2001 From: Cell <1024@lruihao.cn> Date: Sat, 10 May 2025 10:41:55 +0800 Subject: [PATCH] :wrench: Feat(workflow): replace auto commit with pull request in actions --- .github/workflows/fixit-component-list.yml | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/.github/workflows/fixit-component-list.yml b/.github/workflows/fixit-component-list.yml index 04bfec95..829e741b 100644 --- a/.github/workflows/fixit-component-list.yml +++ b/.github/workflows/fixit-component-list.yml @@ -5,6 +5,7 @@ on: workflow_dispatch: # Run workflow manually (without waiting for the cron to be called), through the GitHub Actions Workflow page directly permissions: contents: write # To write the generated contents to the readme + pull-requests: write # To create a pull request jobs: generate-component-list: @@ -21,8 +22,18 @@ jobs: comment_tag_name: HUGO_FIXIT_COMPONENTS readme_path: 'README.md,README.zh-cn.md' template: "- [{$repo.name}]({$repo.html_url})\\\n {$repo.description}" - - name: Commit changes - uses: stefanzweifel/git-auto-commit-action@v5 + # - name: Commit changes + # uses: stefanzweifel/git-auto-commit-action@v5 + # with: + # commit_message: ':memo: Docs: update hugo-fixit component list' + # commit_author: 'github-actions[bot] ' + - name: Create Pull Request + uses: peter-evans/create-pull-request@v7 with: - commit_message: ':memo: Docs: update hugo-fixit component list' - commit_author: 'github-actions[bot] ' + title: 'Update hugo-fixit component list' + commit-message: ':memo: Docs: update hugo-fixit component list' + body: 'This PR updates the hugo-fixit component list in the README.' + base: main + branch: update-component-list + labels: documentation + reviewers: Lruihao