Skip to content

Commit 91c7c87

Browse files
ovitrifclaude
andcommitted
fix: use code-review plugin for Claude review workflow
Remove custom prompt and restricted claude_args that prevented Claude from using essential tools (Read, Grep, Glob, Agent). Switch to the official code-review plugin which works correctly on bitkit-ios. Also disable rustfmt cron to prevent automated PRs. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 3f4c563 commit 91c7c87

2 files changed

Lines changed: 17 additions & 24 deletions

File tree

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

Lines changed: 16 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -24,27 +24,24 @@ jobs:
2424
fetch-depth: 1
2525

2626
- name: Minimize old Claude comments
27-
uses: actions/github-script@v7
28-
with:
29-
script: |
30-
const { data: comments } = await github.rest.issues.listComments({
31-
owner: context.repo.owner,
32-
repo: context.repo.repo,
33-
issue_number: context.payload.pull_request.number,
34-
per_page: 100,
35-
});
36-
const claudeComments = comments.filter(c =>
37-
c.user?.login === 'claude[bot]' || c.user?.login === 'github-actions[bot]'
38-
);
39-
for (const comment of claudeComments) {
40-
await github.graphql(`
41-
mutation MinimizeComment($id: ID!) {
42-
minimizeComment(input: { subjectId: $id, classifier: OUTDATED }) {
27+
env:
28+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
run: |
30+
REPO="${{ github.repository }}"
31+
PR_NUMBER="${{ github.event.pull_request.number }}"
32+
33+
# Minimize issue comments from claude[bot]
34+
gh api "repos/$REPO/issues/$PR_NUMBER/comments" --jq '.[] | select(.user.login == "claude[bot]") | .node_id' | while read -r node_id; do
35+
if [ -n "$node_id" ]; then
36+
echo "Minimizing comment: $node_id"
37+
gh api graphql -f query='
38+
mutation($id: ID!) {
39+
minimizeComment(input: {subjectId: $id, classifier: OUTDATED}) {
4340
minimizedComment { isMinimized }
4441
}
45-
}
46-
`, { id: comment.node_id });
47-
}
42+
}' -f id="$node_id" || true
43+
fi
44+
done
4845
4946
- name: Run Claude Code Review
5047
id: claude-review
@@ -54,5 +51,3 @@ jobs:
5451
plugin_marketplaces: 'https://github.com/anthropics/claude-code.git'
5552
plugins: 'code-review@claude-code-plugins'
5653
prompt: '/code-review:code-review ${{ github.repository }}/pull/${{ github.event.pull_request.number }}'
57-
allowed_bots: 'claude[bot]'
58-
claude_args: '--allowed-tools Bash(gh:*) WebFetch'

.github/workflows/cron-weekly-rustfmt.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@ permissions:
55
pull-requests: write
66

77
on:
8-
schedule:
9-
- cron: "0 0 * * 0" # runs weekly on Sunday at 00:00
10-
workflow_dispatch: # allows manual triggering
8+
workflow_dispatch: # manual only — cron schedule removed to avoid automated PRs
119
jobs:
1210
format:
1311
name: Nightly rustfmt

0 commit comments

Comments
 (0)