]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
github: guide Claude to use inline comments and be concise
authorHauke Mehrtens <hauke@hauke-m.de>
Sat, 11 Apr 2026 16:07:01 +0000 (18:07 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Sun, 12 Apr 2026 15:02:00 +0000 (17:02 +0200)
Instruct Claude to prefer inline comments for file/line-specific
findings and keep all feedback short and to the point.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Link: https://github.com/openwrt/openwrt/pull/22897
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
.github/workflows/claude-code-review.yml

index d53f085f22504713b2cf48a2c0ff70ebcbcb676f..757743d7e5e9e3ea9945e89926747630d8bc4fd0 100644 (file)
@@ -34,3 +34,15 @@ jobs:
           claude_args: >-
             --allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(grep:*)"
             --disallowedTools "Bash(git add:*),Bash(git commit:*),Bash(git rm:*),Bash(git push:*)"
+        env:
+          APPEND_SYSTEM_PROMPT: >-
+            IMPORTANT: For any issue tied to a specific file and line number,
+            you MUST call mcp__github_inline_comment__create_inline_comment to
+            post it as an inline comment on the diff. This is a separate
+            channel from mcp__github_comment__update_claude_comment and does
+            NOT violate the "only update your tracking comment" rule — both
+            tools should be used. Do NOT put line-specific issues in the
+            top-level tracking comment. Only use the top-level tracking
+            comment for a brief overall verdict. Never describe or summarize
+            what the PR does. Only report actual problems, concerns, or
+            suggestions. If nothing is wrong, say so in one short sentence.