CI: Claude Code agent that fixes issues labelled claude-ok and opens pull requests (never merges) #114

Closed
norixodev wants to merge 1 commit from upstream-pr/114 into main
norixodev commented 2026-11-25 14:29:51 +00:00 (Migrated from github.com)

Imported from Belobug/VIctory-Belobug-AMD. Originally posted by norixodev on 2026-11-25T14:29:51Z.


Adds .github/workflows/claude-agent.yml, an issue agent built on Claude Code. It runs every 6 hours or by hand ("Run workflow"):

  1. It takes the oldest open issue labelled claude-ok and claims it: label claude-wip plus a comment.
  2. Claude Code fixes it on claude/issue-N, then runs clippy and cargo test. Its tools are limited to read, edit, cargo and git commit. It has no push, no gh, no web access, and no GitHub token.
  3. The workflow runs cargo test again and opens a pull request. The pull request is a draft if the tests fail.
  4. If Claude can't fix the issue, the issue is labelled claude-failed with the reason.
  5. It never merges. Every pull request waits for a maintainer.

Only issues a maintainer labels claude-ok are taken. Most issues here need the game or an AMD GPU, which the runner doesn't have.

ci.yml gets workflow_dispatch. Pushes made with GITHUB_TOKEN start no workflows, so the agent starts CI on its own branch.

To enable it after merging:

  • Add the secret ANTHROPIC_API_KEY (or CLAUDE_CODE_OAUTH_TOKEN).
  • Turn on Settings → Actions → General → "Allow GitHub Actions to create and approve pull requests".
  • Recommended: protect main with a required review.

Not run yet. Test it with "Run workflow" on one labelled issue.

🤖 Generated with Claude Code

<!-- greyfinch-sync:Belobug/VIctory-Belobug-AMD:issue:6606807004 --> Imported from [Belobug/VIctory-Belobug-AMD](https://github.com/Belobug/VIctory-Belobug-AMD/pull/114). Originally posted by [norixodev](https://github.com/norixodev) on 2026-11-25T14:29:51Z. --- Adds `.github/workflows/claude-agent.yml`, an issue agent built on Claude Code. It runs every 6 hours or by hand ("Run workflow"): 1. It takes the oldest open issue labelled `claude-ok` and claims it: label `claude-wip` plus a comment. 2. Claude Code fixes it on `claude/issue-N`, then runs clippy and `cargo test`. Its tools are limited to read, edit, `cargo` and `git commit`. It has no push, no `gh`, no web access, and no GitHub token. 3. The workflow runs `cargo test` again and opens a pull request. The pull request is a draft if the tests fail. 4. If Claude can't fix the issue, the issue is labelled `claude-failed` with the reason. 5. **It never merges.** Every pull request waits for a maintainer. Only issues a maintainer labels `claude-ok` are taken. Most issues here need the game or an AMD GPU, which the runner doesn't have. `ci.yml` gets `workflow_dispatch`. Pushes made with `GITHUB_TOKEN` start no workflows, so the agent starts CI on its own branch. **To enable it after merging:** - Add the secret `ANTHROPIC_API_KEY` (or `CLAUDE_CODE_OAUTH_TOKEN`). - Turn on Settings → Actions → General → "Allow GitHub Actions to create and approve pull requests". - Recommended: protect `main` with a required review. Not run yet. Test it with "Run workflow" on one labelled issue. 🤖 Generated with [Claude Code](https://claude.com/claude-code)

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Belobug/VIctory-Belobug-AMD!114
No description provided.