Skip to content
Closed
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
4 changes: 3 additions & 1 deletion .github/workflows/apply-auto-fixes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,16 @@ jobs:
# Use the GitHub API to check if the 'auto-fixes-patch' artifact exists for the triggering workflow run.
# The artifacts_url is a pre-authenticated API endpoint.
# We use jq to parse the JSON response and see if our artifact is in the list.
artifact_json=$(curl -s "${{ github.event.workflow_run.artifacts_url }}")
artifact_json=$(curl -s "${GITHUB_EVENT_WORKFLOW_RUN_ARTIFACTS_URL}")
if echo "$artifact_json" | jq -e '.artifacts[] | select(.name == "auto-fixes-patch")' > /dev/null; then
echo "Patch artifact found."
echo "exists=true" >> $GITHUB_OUTPUT
else
echo "No patch artifact was uploaded."
echo "exists=false" >> $GITHUB_OUTPUT
fi
env:
GITHUB_EVENT_WORKFLOW_RUN_ARTIFACTS_URL: ${{ github.event.workflow_run.artifacts_url }}

- name: Checkout PR branch
if: steps.check_artifact.outputs.exists == 'true'
Expand Down
Loading