temp: skip if branch already exists instead of checking for PR

This commit is contained in:
bitterpanda 2026-05-19 14:56:04 -07:00
parent 0b46c5408b
commit f2cce7b7e9

View file

@ -63,9 +63,8 @@ jobs:
OLD="${{ steps.current.outputs.version }}" OLD="${{ steps.current.outputs.version }}"
BRANCH="bump/endpoint-${NEW}" BRANCH="bump/endpoint-${NEW}"
# Skip if a PR for this version already exists if git ls-remote --exit-code --heads origin "$BRANCH" &>/dev/null; then
if gh pr list --head "$BRANCH" --json number --jq '.[0].number' | grep -q '[0-9]'; then echo "Branch $BRANCH already exists, skipping."
echo "PR for $NEW already open, skipping."
exit 0 exit 0
fi fi