Merge pull request #11423 from cli/babakks/fix-help-wanted-label-regexp

Fix `help wanted` label regexp in CI automation
This commit is contained in:
Babak K. Shandiz 2025-07-31 16:23:04 +01:00 committed by GitHub
commit 68887865c1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -56,7 +56,7 @@ for issue_num in $CLOSING_ISSUES; do
fi
# Check if 'help wanted' label exists
if ! echo "$LABELS" | grep -q "help wanted"; then
if ! echo "$LABELS" | grep -qE '^help wanted$'; then
ISSUES_WITHOUT_HELP_WANTED+=("$issue_num")
echo "Issue #$issue_num does not have 'help wanted' label"
else
@ -78,7 +78,7 @@ if [ ${#ISSUES_WITHOUT_HELP_WANTED[@]} -gt 0 ]; then
gh pr comment "$PR_URL" --body-file - <<EOF
Thank you for your pull request! 🎉
This PR appears to fix the following issues that are not labeled with \`help wanted\`:
This PR appears to fix the following issues that are not labeled with https://github.com/cli/cli/labels/help%20wanted:
$ISSUE_LIST
As outlined in our [Contributing Guidelines](https://github.com/cli/cli/blob/trunk/.github/CONTRIBUTING.md), we expect that PRs are only created for issues that have been labeled \`help wanted\`.