Skip to content

Commit

Permalink
Disable linkcheck in PRs until bugs are fixed
Browse files Browse the repository at this point in the history
See Michael-F-Bryan/mdbook-linkcheck#77
and Michael-F-Bryan/mdbook-linkcheck#86.

These bugs are causing linkcheck to erroneously fail because we run it
using `-f`, to avoid too many requests. For now, disable linkcheck in PR
CI, though leave it enabled in the cron job, where the bug should not
occur.
  • Loading branch information
camelid committed Aug 8, 2024
1 parent 9c47f8c commit ed3365e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ci/linkcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ if [ "$GITHUB_EVENT_NAME" = "schedule" ] ; then # running in scheduled job

echo "Doing full link check."
elif [ "$GITHUB_EVENT_NAME" = "pull_request" ] ; then # running in PR CI build
echo "*** WARNING: linkcheck temporarily disabled due to bugs ***"
exit 0

if [ -z "$BASE_SHA" ]; then
echo "error: unexpected state: BASE_SHA must be non-empty in CI"
exit 1
Expand All @@ -25,6 +28,9 @@ elif [ "$GITHUB_EVENT_NAME" = "pull_request" ] ; then # running in PR CI build

echo "Checking files changed since $BASE_SHA: $CHANGED_FILES"
else # running locally
echo "*** WARNING: linkcheck temporarily disabled due to bugs ***"
exit 0

COMMIT_RANGE=master...
CHANGED_FILES=$(git diff --name-only $COMMIT_RANGE | sed 's#^src/##' | tr '\n' ' ')
FLAGS="-f $CHANGED_FILES"
Expand Down

0 comments on commit ed3365e

Please sign in to comment.