Skip to content

Fix GRAV_CONFIG env override gate to also check $_SERVER/$_ENV #58

Fix GRAV_CONFIG env override gate to also check $_SERVER/$_ENV

Fix GRAV_CONFIG env override gate to also check $_SERVER/$_ENV #58

name: Claude Code Review
on:
# Auto-review internal PRs (branches pushed to this repo, not forks).
pull_request:
types: [opened, synchronize, ready_for_review, reopened]
# Manual review of any PR (including forks): add the "claude-review" label.
pull_request_target:
types: [labeled]
# Manual review from the Actions tab: enter a PR number and click "Run workflow".
workflow_dispatch:
inputs:
pr_number:
description: 'PR number to review'
required: true
jobs:
claude-review:
# Run when:
# - it's an internal (non-fork) pull_request, OR
# - the "claude-review" label was just added to a PR, OR
# - it was started manually from the Actions tab.
if: |
(github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) ||
(github.event_name == 'pull_request_target' && github.event.label.name == 'claude-review') ||
(github.event_name == 'workflow_dispatch')
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
issues: write
id-token: write
actions: read # Required for Claude to read CI results on PRs
steps:
- name: Checkout repository
uses: actions/checkout@v7
with:
fetch-depth: 1
- name: Determine PR number
id: pr
run: echo "number=${{ github.event.inputs.pr_number || github.event.pull_request.number }}" >> "$GITHUB_OUTPUT"
- name: Run Claude Code Review
id: claude-review
uses: anthropics/claude-code-action@v1
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
plugin_marketplaces: 'https://github.com/anthropics/claude-code.git'
plugins: 'code-review@claude-code-plugins'
prompt: '/code-review:code-review ${{ github.repository }}/pull/${{ steps.pr.outputs.number }}'
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
# or https://code.claude.com/docs/en/cli-reference for available options