github-actions-plugin/skills/claude-code-github-workflows/SKILL.md
Claude Code GitHub Actions workflow patterns — PR reviews, issue triage, CI/CD integration. Use when creating or modifying workflows that integrate Claude Code.
npx skillsauth add laurigates/claude-plugins claude-code-github-workflowsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
| Use this skill when... | Use the linked sibling instead when... |
|---|---|
| Designing a new anthropics/claude-code-action@v1 workflow (PR review, issue triage, CI auto-fix) | Configuring the auth method or hardening permissions — see github-actions-auth-security |
| Choosing trigger events (issue_comment, pull_request, workflow_run) and if: guards | Wiring MCP servers and --allowedTools patterns — see github-actions-mcp-config |
| Adding path filters, custom trigger phrases, or external-contributor flows | Debugging a failing workflow run — see github-actions-inspection |
| Authoring the prompt: block (review focus areas, triage labelling, auto-fix instructions) | Building a self-hosted reusable auto-fix workflow — see github-workflow-auto-fix --reusable |
Expert knowledge for designing GitHub Actions workflows that integrate Claude Code for automated code assistance, PR reviews, and issue triage.
Workflow Design Patterns
Trigger Configurations
@claude mentions)Every workflow's name: follows <Domain>: <Action> [<target>] (quoted, since YAML treats : as a key separator). Use the Claude: domain for Claude Code-driven workflows; use Auto-fix: for workflow_run-triggered remediation. See .claude/rules/workflow-naming.md for the canonical rule and active domains. The example snippets below dogfood the convention.
When a workflow's on.workflow_run.workflows lists another workflow's display name, the listed string must match the target workflow's name: exactly — update both sides in the same change.
name: "Claude: @mentions"
on:
issue_comment:
types: [created]
pull_request_review_comment:
types: [created]
issues:
types: [opened, assigned]
jobs:
claude:
if: |
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
(github.event_name == 'issues' && contains(github.event.issue.body, '@claude'))
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
issues: write
id-token: write
actions: read
steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
fetch-depth: 1
- name: Run Claude Code
uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
name: "Claude: PR review"
on:
pull_request:
types: [opened, synchronize, ready_for_review, reopened]
jobs:
review:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
id-token: write
steps:
- uses: actions/checkout@v5
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
track_progress: true
prompt: |
Review this PR focusing on:
1. Code Quality
2. Security
3. Performance
4. Testing
5. Documentation
name: "Auto-fix: CI failures"
on:
workflow_run:
# The string here must match the target workflow's `name:` exactly.
workflows: ["Test: Suite"]
types: [completed]
jobs:
auto-fix:
if: github.event.workflow_run.conclusion == 'failure'
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
actions: read
steps:
- uses: actions/checkout@v5
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: |
The CI workflow failed. Please:
1. Analyze the failure logs
2. Identify the root cause
3. Implement a fix
4. Create a PR with the fix
name: "Claude: Issue triage"
on:
issues:
types: [opened]
jobs:
triage:
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: |
Analyze this issue and:
1. Add appropriate labels (bug, feature, documentation, etc.)
2. Suggest a priority level
3. Recommend assignment if obvious
4. Ask clarifying questions if needed
name: "Claude: Review backend changes"
on:
pull_request:
paths:
- 'backend/**'
- 'api/**'
jobs:
review:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: actions/checkout@v5
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: |
Review backend changes focusing on:
- API design and RESTful principles
- Database query optimization
- Error handling and logging
- Security vulnerabilities
name: "Claude: Custom trigger"
on:
issue_comment:
types: [created]
jobs:
claude:
if: contains(github.event.comment.body, '/claude-review')
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
issues: write
steps:
- uses: actions/checkout@v5
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
trigger_phrase: "/claude-review"
name: "Claude: Review external contributions"
on:
pull_request_target:
types: [opened]
jobs:
review:
if: github.event.pull_request.author_association == 'FIRST_TIME_CONTRIBUTOR'
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v5
with:
ref: ${{ github.event.pull_request.head.sha }}
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: |
Welcome first-time contributor! Review this PR for:
- Code quality and style compliance
- Test coverage
- Documentation updates
- Security concerns
Provide helpful, constructive feedback.
# Fast checkout for large repos
- uses: actions/checkout@v5
with:
fetch-depth: 1 # Shallow clone
sparse-checkout: | # Only needed paths
.github
src
tests
# Control execution time and cost
claude_args: |
--max-turns 10 # Limit back-and-forth exchanges
# Skip unnecessary runs
jobs:
claude:
if: |
contains(github.event.comment.body, '@claude') &&
!contains(github.event.comment.body, 'ignore')
Create CLAUDE.md in repository root to define coding standards:
# Repository Guidelines for Claude Code
## Code Standards
- Use TypeScript strict mode
- Follow Airbnb style guide
- Maintain 90%+ test coverage
- Document all public APIs
## Development Workflow
- Run tests before committing: `npm test`
- Format with Prettier: `npm run format`
- Lint with ESLint: `npm run lint`
## Commit Messages
Follow Conventional Commits:
- feat: New features
- fix: Bug fixes
- docs: Documentation changes
- refactor: Code refactoring
## Testing Requirements
- Unit tests for all functions
- Integration tests for APIs
- E2E tests for critical flows
## Security
- Never commit secrets
- Validate all user inputs
- Use parameterized queries
- Follow OWASP guidelines
ANTHROPIC_API_KEY.github/workflows/claude.yml (use template above)@claude Hello!CLAUDE.md in repo root for project standardsif: clauseFor advanced configuration including MCP servers, tool permissions, and authentication methods, see the github-actions-mcp-config and github-actions-auth-security skills.
tools
Scaffold a new ComfyUI custom-node repo (pyproject, CI, release-please, vitest+pytest, JS extension skeleton) in the picker/gesture vein. Use when bootstrapping or init-ing a comfyui node pack.
tools
Orchestrate a ComfyUI node pack from idea to registry: scaffold, create + seed the repo, open the gitops adoption PR. Use when releasing or spinning up a new comfyui node pack.
testing
macOS EndpointSecurity/EDR high CPU & battery drain. Use when Kandji ESF / XProtect pegs a core; trace the exec storm via powermetrics + eslogger.
development
odiff pixel-by-pixel image diffing. Use when comparing screenshots, detecting visual regressions, diffing before/after PNGs, asserting golden images.