Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .github/workflows/pull-review-crush.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
env:
COMMENT_BODY: ${{ github.event.comment.body }}
run: |
# Check for {{provider, model}} or {{provider, model, small_model}} override syntax at comment start
# Check for {{provider, model}} or {{provider, model, small_model}} override syntax after /crush or /crush_fast command
if [[ "$COMMENT_BODY" =~ ^[[:space:]]*/crush(_fast)?[[:space:]]+\{\{[[:space:]]*([^,]+)[[:space:]]*,[[:space:]]*([^,}]+)[[:space:]]*(,[[:space:]]*([^}]+)[[:space:]]*)?\}\} ]]; then
PROVIDER=$(echo "${BASH_REMATCH[2]}" | xargs)
MODEL=$(echo "${BASH_REMATCH[3]}" | xargs)
Expand Down Expand Up @@ -124,6 +124,7 @@ jobs:
case "$REVIEW_PROVIDER" in
openrouter) echo "CRUSH_SMALL_MODEL=openrouter/$SMALL_MODEL" >> "$GITHUB_ENV" ;;
zai-coding-plan) echo "CRUSH_SMALL_MODEL=zai/$SMALL_MODEL" >> "$GITHUB_ENV" ;;
*) echo "CRUSH_SMALL_MODEL=zai/glm-4.7" >> "$GITHUB_ENV" ;;
esac

- name: Get PR number
Expand All @@ -141,6 +142,7 @@ jobs:
echo "base_ref=$(jq -r '.base.ref' pr_data.json)"
} >> "$GITHUB_OUTPUT"
jq -r '.body // ""' pr_data.json > /tmp/pr_body.txt
jq -r '.title // ""' pr_data.json > /tmp/pr_title.txt

- name: Check for linked issue
id: check-issue
Expand Down Expand Up @@ -218,7 +220,7 @@ jobs:
ISSUE_NUMBER: ${{ steps.check-issue.outputs.issue_number }}
run: |
# Start with PR title
printf '<pr_title>\n%s\n</pr_title>\n' "$(jq -r '.title // ""' pr_data.json)" > /tmp/helpful_context.txt
printf '<pr_title>\n%s\n</pr_title>\n' "$(cat /tmp/pr_title.txt)" > /tmp/helpful_context.txt

if [ "$HAS_ISSUE" = "true" ]; then
# Fetch the issue
Expand Down