Files
claude-code-gitea-action/.github/workflows/claude.yml
Mark Wylde ba45e9da7a chore: update model IDs in docs and workflows to current models
claude-3-7-sonnet-20250219 was retired on 2026-02-19 and now returns 404,
and claude-opus-4-1-20250805 is deprecated (retires 2026-08-05). Replace
with claude-sonnet-4-6 / claude-opus-4-8 for the Anthropic API and the
dated Sonnet 4.5 IDs for the Bedrock/Vertex provider-specific formats.
2026-06-11 20:55:26 +01:00

41 lines
1.3 KiB
YAML

name: Claude Code
on:
issue_comment:
types: [created]
pull_request_review_comment:
types: [created]
issues:
types: [opened, assigned]
pull_request_review:
types: [submitted]
jobs:
claude:
if: |
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
(github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) ||
(github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude')) ||
(github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude')))
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
issues: read
id-token: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Run Claude Code
id: claude
uses: anthropics/claude-code-action@v1
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
github_token: ${{ secrets.GITHUB_TOKEN }}
claude_args: |
--allowedTools "Bash(bun install),Bash(bun test:*),Bash(bun run format),Bash(bun typecheck)"
--model "claude-opus-4-8"