Skip to content

Add Claude Code GitHub Workflow#215

Draft
riscait wants to merge 4 commits intomainfrom
add-claude-github-actions-1750330204848
Draft

Add Claude Code GitHub Workflow#215
riscait wants to merge 4 commits intomainfrom
add-claude-github-actions-1750330204848

Conversation

@riscait
Copy link
Member

@riscait riscait commented Jun 19, 2025

🤖 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 documentation.

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

Copilot AI review requested due to automatic review settings June 19, 2025 10:50
@riscait riscait requested a review from a team as a code owner June 19, 2025 10:50
@riscait riscait requested review from k-nkmr and naipaka and removed request for a team June 19, 2025 10:50
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR introduces GitHub Actions workflows to integrate Claude Code features into the repository, enabling automated responses to code review requests and issue/PR comments that mention @claude.

  • Added workflow (.github/workflows/claude.yml) to trigger Claude Code on issue comments, PR review comments, issues, and PR reviews.
  • Added workflow (.github/workflows/claude-code-review.yml) for automated code review on pull request events, with customizable prompts and optional configurations.

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
.github/workflows/claude.yml Implements triggers and jobs for interacting with Claude Code via repository comments and events.
.github/workflows/claude-code-review.yml Sets up an automated code review workflow using a direct prompt for Claude Code Review.
Comments suppressed due to low confidence (2)

.github/workflows/claude.yml:15

  • Add an inline comment above the 'if' condition to clarify that the block checks for the '@claude' trigger in different event types, enhancing clarity for future maintainers.
    if: |

.github/workflows/claude-code-review.yml:6

  • [nitpick] Consider removing or relocating optional configuration comments (like file path filters) if they are not in use, to improve workflow readability.
    # Optional: Only run on specific file changes

@claude
Copy link

claude bot commented Jun 19, 2025

Claude encountered an error —— View job


I'll analyze this and get back to you.

@claude
Copy link

claude bot commented Jun 19, 2025

Claude encountered an error —— View job


I'll analyze this and get back to you.

@riscait riscait marked this pull request as draft June 19, 2025 23:20
@claude
Copy link

claude bot commented Jun 20, 2025

Claude encountered an error —— View job


I'll analyze this and get back to you.

1 similar comment
@claude
Copy link

claude bot commented Jun 20, 2025

Claude encountered an error —— View job


I'll analyze this and get back to you.

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