-
-
Notifications
You must be signed in to change notification settings - Fork 101
ci: add Claude Code GitHub Action integration #152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
e22f028
ci: add Claude Code GitHub Action integration
kirich1409 711e51b
refactor: update Claude Code config for project specifics
kirich1409 85b8b44
fix: address PR review comments for Claude workflow
kirich1409 54052ee
refactor: simplify Claude workflow, remove redundant logic
kirich1409 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,58 @@ | ||
| 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: | ||
| # Only allow trusted collaborators to trigger Claude | ||
| if: | | ||
| github.event.comment.author_association == 'OWNER' || | ||
| github.event.comment.author_association == 'MEMBER' || | ||
| github.event.comment.author_association == 'COLLABORATOR' || | ||
| github.event.review.author_association == 'OWNER' || | ||
| github.event.review.author_association == 'MEMBER' || | ||
| github.event.review.author_association == 'COLLABORATOR' || | ||
| github.event.issue.author_association == 'OWNER' || | ||
| github.event.issue.author_association == 'MEMBER' || | ||
| github.event.issue.author_association == 'COLLABORATOR' | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| issues: write | ||
| actions: read | ||
| steps: | ||
| - name: Checkout repository | ||
| uses: actions/checkout@v6 | ||
|
|
||
| - name: Set up JDK 21 | ||
| uses: actions/setup-java@v5 | ||
| with: | ||
| java-version: '21' | ||
| distribution: 'temurin' | ||
| cache: gradle | ||
|
|
||
| - name: Grant execute permission for gradlew | ||
| run: chmod +x gradlew | ||
|
|
||
| - name: Setup Gradle | ||
| uses: gradle/actions/setup-gradle@v4 | ||
|
|
||
|
kirich1409 marked this conversation as resolved.
kirich1409 marked this conversation as resolved.
|
||
| - name: Run Claude Code | ||
| id: claude | ||
| uses: anthropics/claude-code-action@v1 | ||
| with: | ||
| anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }} | ||
| claude_args: | | ||
| --model claude-opus-4-6 | ||
| --max-turns 20 | ||
| --allowedTools "Bash(./gradlew check),Bash(./gradlew assembleRelease),Bash(./gradlew ktlintFormat),Bash(./gradlew ktlintCheck),Bash(./gradlew detekt),Bash(./gradlew testDebugUnitTest),Bash(./gradlew koverHtmlReport),Bash(./gradlew koverXmlReport),Bash(./gradlew :vbpd-core:*),Bash(./gradlew :vbpd:*),Bash(./gradlew :vbpd-reflection:*),Bash(./gradlew :sample:*),Bash(git status),Bash(git diff),Bash(git log*),Bash(git show*)" | ||
| --system-prompt "Android library project (ViewBindingPropertyDelegate). Three modules: vbpd-core (foundation), vbpd (lifecycle delegates), vbpd-reflection (reflection + cache). Follow CLAUDE.md: explicit API mode required, Kotlin code style 'official', JVM target 11. Always run ktlintFormat before commit. Use './gradlew check' to verify. PRs → develop (feature/fix/chore/docs branches), hotfixes → master. Version in gradle/libs.versions.toml. Package: dev.androidbroadcast.vbpd." | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.