Skip to content

Add Claude Code GitHub Workflow - #5

Merged
baanish merged 2 commits into
mainfrom
add-claude-github-actions-1773356881090
Mar 12, 2026
Merged

Add Claude Code GitHub Workflow#5
baanish merged 2 commits into
mainfrom
add-claude-github-actions-1773356881090

Conversation

@baanish

@baanish baanish commented Mar 12, 2026

Copy link
Copy Markdown
Owner

🤖 Installing Claude Code GitHub App

This PR adds a GitHub Actions workflow that enables Claude Code integration in our repository.

What is Claude Code?

Claude Code is an AI coding agent that can help with:

  • Bug fixes and improvements
  • Documentation updates
  • Implementing new features
  • Code reviews and suggestions
  • Writing tests
  • And more!

How it works

Once this PR is merged, we'll be able to interact with Claude by mentioning @claude in a pull request or issue comment.
Once the workflow is triggered, Claude will analyze the comment and surrounding context, and execute on the request in a GitHub action.

Important Notes

  • This workflow won't take effect until this PR is merged
  • @claude mentions won't work until after the merge is complete
  • The workflow runs automatically whenever Claude is mentioned in PR or issue comments
  • Claude gets access to the entire PR or issue context including files, diffs, and previous comments

Security

  • Our Anthropic API key is securely stored as a GitHub Actions secret
  • Only users with write access to the repository can trigger the workflow
  • All Claude runs are stored in the GitHub Actions run history
  • Claude's default tools are limited to reading/writing files and interacting with our repo by creating comments, branches, and commits.
  • We can add more allowed tools by adding them to the workflow file like:
allowed_tools: Bash(npm install),Bash(npm run build),Bash(npm run lint),Bash(npm run test)

There's more information in the Claude Code action repo.

After merging this PR, let's try mentioning @claude in a comment on any PR to get started!

Summary by CodeRabbit

  • Chores
    • Added automated code review workflows to enhance development processes and code quality checks.

@baanish
baanish merged commit c4d81fa into main Mar 12, 2026
1 check was pending
@coderabbitai

coderabbitai Bot commented Mar 12, 2026

Copy link
Copy Markdown
Contributor

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: be60b9d5-b653-46fb-8a99-fb6695207342

📥 Commits

Reviewing files that changed from the base of the PR and between a086df1 and 3faaaa5.

📒 Files selected for processing (2)
  • .github/workflows/claude-code-review.yml
  • .github/workflows/claude.yml

📝 Walkthrough

Walkthrough

Two GitHub Actions workflows are added to automate Claude-powered code review and interactive code assistance. One workflow triggers automatically on pull request events for code review, while the other enables manual invocation via @claude mentions in issue and pull request comments.

Changes

Cohort / File(s) Summary
GitHub Actions Workflows
.github/workflows/claude-code-review.yml, .github/workflows/claude.yml
Adds two new CI/CD workflows integrating Claude Code action. The first (claude-code-review.yml) automatically reviews PRs on open, synchronize, ready\_for\_review, and reopened events. The second (claude.yml) enables interactive assistance via @claude mentions on issues and PR comments. Both workflows configure OAuth authentication, set appropriate permissions (contents, pull-requests, issues, id-token), and include optional customization for additional permissions and prompt configuration.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 Two workflows hop into the fold,
Claude's wisdom, stories yet untold,
From PR reviews to comments swift,
Code quality's a precious gift!
GitHub Actions, our carrots so bright,
Automation sets the coding night right! 🌙✨

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch add-claude-github-actions-1773356881090
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@kilo-code-bot kilo-code-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (2 files)
  • .github/workflows/claude-code-review.yml - Adds automated Claude code review on PR events
  • .github/workflows/claude.yml - Adds Claude bot integration for issue/PR comments

Analysis

Reviewed both GitHub Actions workflow files for security and correctness:

Security:

  • Both workflows properly use secrets.CLAUDE_CODE_OAUTH_TOKEN for OAuth authentication
  • Permissions are appropriately scoped (minimal required permissions)
  • No sensitive data exposure or injection vulnerabilities detected

Correctness:

  • Workflow triggers are properly configured
  • Condition logic in claude.yml correctly filters for @claude mentions
  • Both workflows use the official anthropics/claude-code-action

No critical issues, runtime errors, or security vulnerabilities were identified. The workflows follow standard GitHub Actions patterns for AI-assisted code review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant