这是indexloc提供的服务,不要输入任何密码
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/claude-code-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,20 @@ jobs:
pull-requests: write
issues: write
id-token: write
env:
OVERRIDE_GITHUB_TOKEN: ${{ secrets.CLAUDE_PAT_TOKEN }}
steps:
# Simply checking out the repository is sufficient - the action handles the PR code
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0 # Get full history for accurate diffs


- name: Run Code Review with Claude
uses: anthropics/claude-code-action@beta
env:
OVERRIDE_GITHUB_TOKEN: ${{ secrets.CLAUDE_PAT_TOKEN }}
with:
# Your Anthropic API key
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/claude-comment-response.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ jobs:
issues: write
id-token: write
steps:
# Set environment variables for Claude Code Action
- name: Set up environment
run: |
echo "OVERRIDE_GITHUB_TOKEN=${{ secrets.CLAUDE_PAT_TOKEN }}" >> $GITHUB_ENV
echo "Setting up PAT token for Claude Code Action"

# Simply checking out the repository is sufficient
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -26,9 +32,9 @@ jobs:
# Your Anthropic API key
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}

# Explicitly set the trigger phrase and provide github token
# Explicitly set the trigger phrase
trigger_phrase: "@claude"
github_token: ${{ secrets.GITHUB_TOKEN }}
# Note: Token is provided via OVERRIDE_GITHUB_TOKEN environment variable

# Timeout for execution
timeout_minutes: 20
12 changes: 9 additions & 3 deletions .github/workflows/claude-pr-creation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ jobs:
issues: write
id-token: write
steps:
# Set environment variables for Claude Code Action
- name: Set up environment
run: |
echo "OVERRIDE_GITHUB_TOKEN=${{ secrets.CLAUDE_PAT_TOKEN }}" >> $GITHUB_ENV
echo "Setting up PAT token for Claude Code Action"

# Simply checking out the repository is sufficient
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -44,17 +50,17 @@ jobs:
git status
git branch
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.CLAUDE_PAT_TOKEN }}

- name: Claude PR Creation
uses: anthropics/claude-code-action@beta
with:
# Your Anthropic API key
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}

# Explicitly set the trigger phrase and provide github token
# Explicitly set the trigger phrase
trigger_phrase: "@claude"
github_token: ${{ secrets.GITHUB_TOKEN }}
# Note: Token is provided via OVERRIDE_GITHUB_TOKEN environment variable

# Timeout for execution (longer for PR creation)
timeout_minutes: 30
Loading