Skip to content

Commit df21b53

Browse files
committed
*** TESTING ONLY ***
1 parent 1865de8 commit df21b53

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

.github/workflows/check-urls.yml

+8-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@
66
name: Check URLs
77

88
on:
9-
schedule:
10-
- cron: '0 4 * * 2' # Tues 4:00 AM UTC
9+
pull_request:
10+
branches:
11+
- bugfix-2.1.x
1112

1213
jobs:
1314
check_urls:
@@ -35,6 +36,7 @@ jobs:
3536
run: |
3637
UA="Mozilla/5.0 (Linux; Android 10; SM-G996U Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Mobile Safari/537.36"
3738
UTMP=$(mktemp)
39+
echo "[debug 1] UTMP = ${UTMP}"
3840
echo "Gathering URLs. Please wait..."
3941
grep -R -E "https?:\/\/[^ \"''\(\)\<\>]+" . 2>/dev/null \
4042
| grep -v "Binary file" \
@@ -48,6 +50,7 @@ jobs:
4850
| sort -u -R \
4951
>"$UTMP"
5052
53+
echo "[debug 2] link count = $(wc -l $UTMP)"
5154
ISERR=
5255
declare -a BADURLS
5356
while IFS= read -r URL
@@ -81,13 +84,16 @@ jobs:
8184
fi
8285
done <"$UTMP"
8386
87+
echo "[debug 3]"
8488
if [[ -n $ISERR ]]; then
8589
# Join bad URLs into a bulleted markdown list
8690
printf -v BADSTR -- "- %s\n" "${BADURLS[@]}"
8791
BODY=$(echo -e "URL Checker reports one or more URLs could not be reached:\n${BADSTR}")
8892
echo -e "\n$BODY"
8993
gh issue comment 26975 --repo $GITHUB_REPOSITORY --body "${BODY}"
9094
exit 1
95+
else
96+
gh issue comment 26975 --body "Comment generated by action."
9197
fi
9298
9399
echo -e "\nURL Check Passed."

0 commit comments

Comments
 (0)