File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -43,12 +43,18 @@ jobs:
4343 - name : Determine label based on branch
4444 if : always()
4545 id : label
46+ env :
47+ GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
4648 run : |
4749 LABEL_NAME="broken-link-${{ matrix.branch }}"
48- if ! gh label list | grep -q "^${LABEL_NAME}\b"; then
49- gh label create "${LABEL_NAME}" --description "Indicates broken links in branch ${{ matrix.branch }}"
50+ if gh label list -L 1000 | grep -q "^${LABEL_NAME}\b"; then
51+ echo "Label ${LABEL_NAME} already exists"
52+ else
53+ echo "Creating label ${LABEL_NAME}"
54+ gh label create "${LABEL_NAME}" \
55+ --description "Indicates broken links in branch ${{ matrix.branch }}"
5056 fi
51- echo "label=$LABEL_NAME" >> $GITHUB_OUTPUT
57+ echo "label=$LABEL_NAME" >> $GITHUB_OUTPU
5258
5359 - name : Create GitHub issue if tests fail
5460 if : failure()
You can’t perform that action at this time.
0 commit comments