Skip to content

Commit

Permalink
simplify more
Browse files Browse the repository at this point in the history
  • Loading branch information
lmolkova committed Jan 20, 2025
1 parent 5a4d30d commit 06395f4
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions .github/workflows/scripts/prepare-new-issue.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,10 @@ else
echo "No related areas were given"
fi

if [[ -n "${LABELS}" ]]; then
# Notes on this call:
# 1. Labels will be deduplicated by the GitHub CLI.
# 2. The call to edit the issue will fail if any of the
# labels doesn't exist. We can be reasonably sure that
# all labels will exist since they come from a known set.
echo "Adding the following labels: ${LABELS//,/ /}"
gh issue edit "${ISSUE}" --add-label "${LABELS}" || true
else
echo "No labels were found to add"
fi
# Notes on this call:
# 1. Labels will be deduplicated by the GitHub CLI.
# 2. The call to edit the issue will fail if any of the
# labels doesn't exist. We can be reasonably sure that
# all labels will exist since they come from a known set.
echo "Adding the following labels: ${LABELS//,/ /}"
gh issue edit "${ISSUE}" --add-label "${LABELS}" || true

0 comments on commit 06395f4

Please sign in to comment.