From 29f6a1dc8bf6682d735f4dfd6dac5f7fb9f9f079 Mon Sep 17 00:00:00 2001 From: icarus Date: Sat, 6 Sep 2025 01:54:10 +0800 Subject: [PATCH] =?UTF-8?q?ci(workflows):=20=E6=9B=B4=E6=96=B0Claude?= =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E6=B5=81=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 添加track_progress选项以跟踪代码审查进度 补充环境信息变量和注释说明 --- .github/workflows/claude-code-review.yml | 8 ++++++++ .github/workflows/claude.yml | 1 + 2 files changed, 9 insertions(+) diff --git a/.github/workflows/claude-code-review.yml b/.github/workflows/claude-code-review.yml index 9553ef6a91..404b2e3ccb 100644 --- a/.github/workflows/claude-code-review.yml +++ b/.github/workflows/claude-code-review.yml @@ -37,6 +37,8 @@ jobs: uses: anthropics/claude-code-action@v1 with: claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }} + # https://github.com/anthropics/claude-code-action/blob/main/docs/solutions.md + track_progress: true prompt: | Please review this pull request and provide feedback on: - Code quality and best practices @@ -45,10 +47,16 @@ jobs: - Security concerns - Test coverage + Environment: + + - Repo: ${{ github.event.repository }} + - PR number: ${{ github.event.pull_request.number }} + Use the repository's CLAUDE.md for guidance on style and conventions. Be constructive and helpful in your feedback. Use `gh pr comment` with your Bash tool to leave your review as a comment on the PR. # See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md # or https://docs.anthropic.com/en/docs/claude-code/sdk#command-line for available options + # May allow inline comment mcp here? claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' diff --git a/.github/workflows/claude.yml b/.github/workflows/claude.yml index ba1fcb97aa..5aef92d4bb 100644 --- a/.github/workflows/claude.yml +++ b/.github/workflows/claude.yml @@ -35,6 +35,7 @@ jobs: issues: read id-token: write actions: read # Required for Claude to read CI results on PRs + steps: - name: Checkout repository uses: actions/checkout@v4