From 482511d44fb078e4b38d1ea243a10de5e36fb4a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Miko=C5=82ajczak?= Date: Mon, 25 May 2026 16:31:15 +0200 Subject: [PATCH] chore: adopt postCodeReviewResults.sh from claude-review-toolkit Replaces the inline jq+while-loop in the 'Post code review results' step with a single postCodeReviewResults.sh call. Behaviour identical to today: 0 violations leaves a +1 reaction, otherwise N inline comments are posted via createInlineComment.sh. Bumps the claude-review-toolkit pin to the SHA that introduces the new script. --- .github/workflows/claude-review.yml | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/.github/workflows/claude-review.yml b/.github/workflows/claude-review.yml index ff4ff643644e..c1c420c9cf6d 100644 --- a/.github/workflows/claude-review.yml +++ b/.github/workflows/claude-review.yml @@ -76,7 +76,7 @@ jobs: - name: Setup Claude review toolkit id: toolkit - uses: Expensify/GitHub-Actions/.github/actions/claude-review-toolkit@43c1b4348cd46637e44064b02f5d316bfab990ee + uses: Expensify/GitHub-Actions/.github/actions/claude-review-toolkit@27d36e4f9e124ed03db877cd164f489078398da2 - name: Mark review as in progress env: @@ -103,22 +103,7 @@ jobs: env: GH_TOKEN: ${{ github.token }} STRUCTURED_OUTPUT: ${{ steps.code-review.outputs.structured_output }} - run: | - if [ -z "$STRUCTURED_OUTPUT" ]; then - echo "::error::Claude Code Action returned empty structured output" - exit 1 - fi - COUNT=$(echo "$STRUCTURED_OUTPUT" | jq '.violations | length') - if [ "$COUNT" -eq 0 ]; then - addPrReaction.sh "$PR_NUMBER" "+1" - else - echo "$STRUCTURED_OUTPUT" | jq -c '.violations[]' | while IFS= read -r v; do - PATH_ARG=$(echo "$v" | jq -r '.path') - BODY_ARG=$(echo "$v" | jq -r '.body') - LINE_ARG=$(echo "$v" | jq -r '.line') - createInlineComment.sh "$PR_NUMBER" "$PATH_ARG" "$BODY_ARG" "$LINE_ARG" || true - done - fi + run: postCodeReviewResults.sh "$PR_NUMBER" - name: Run Claude Code (docs) if: steps.filter.outputs.docs == 'true'