From 0397fee1be77757ccd9b6b9017df2477f391b6cd Mon Sep 17 00:00:00 2001 From: bbhtt Date: Mon, 30 Jun 2025 08:47:26 +0530 Subject: [PATCH] pr-check: Remove pr-check-blocked label when resolved --- .github/workflows/pr-check.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pr-check.yml b/.github/workflows/pr-check.yml index de2eb98..692a791 100644 --- a/.github/workflows/pr-check.yml +++ b/.github/workflows/pr-check.yml @@ -123,9 +123,15 @@ jobs: echo "BLOCKED is set to $BLOCKED" - if [ "$BLOCKED" -eq 0 ] && ! label_exists_any "awaiting-changes" "awaiting-upstream" "blocked" "reviewed-waiting"; then - echo "Marking as awaiting-review" - gh pr edit "$PR_NUM" --add-label "awaiting-review" --remove-label "pr-check-blocked" || true + if [ "$BLOCKED" -eq 0 ]; then + if label_exists_any "pr-check-blocked"; then + echo "Removing pr-check-blocked label" + gh pr edit "$PR_NUM" --remove-label "pr-check-blocked" || true + fi + if ! label_exists_any "awaiting-changes" "awaiting-upstream" "blocked" "reviewed-waiting"; then + echo "Marking as awaiting-review" + gh pr edit "$PR_NUM" --add-label "awaiting-review" --remove-label "pr-check-blocked" || true + fi start_build elif [ "$BLOCKED" -eq 1 ]; then echo "Marking as blocked"