From 68c117a2f01c5aab513a8a1d1dedd70fc8e423d7 Mon Sep 17 00:00:00 2001 From: brossetti1 Date: Fri, 21 Feb 2025 12:49:19 -0500 Subject: [PATCH 1/4] adding lychee cron monthly or manually run --- .github/workflows/lychee-cron.yml | 64 +++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 .github/workflows/lychee-cron.yml diff --git a/.github/workflows/lychee-cron.yml b/.github/workflows/lychee-cron.yml new file mode 100644 index 00000000000..bbacfe16e27 --- /dev/null +++ b/.github/workflows/lychee-cron.yml @@ -0,0 +1,64 @@ +name: Check Links In Public Directory + +on: + pull_request: + schedule: + - cron: "0 0 1 * *" # Monthly run on the 1st day of every month at midnight UTC + workflow_dispatch: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + check-links: + runs-on: ubuntu-latest + + steps: + - name: Clone repository + uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: dev + + - name: Check links in /public + uses: lycheeverse/lychee-action@v2 + with: + args: | + public/ + --quiet + --max-retries 1 + --accept 200,429,403 + --exclude-all-private + --exclude '^file://' + --exclude "ethereum\.org" + --include '^https?://' + --format detailed + './**/*.md' + './**/*.html' + output: ./lychee-report.txt + continue-on-error: true + + # looks like we dont need to do this? + # - name: Add Lychee Report to Job Summary + # if: always() + # run: | + # echo "### Lychee Report" >> $GITHUB_STEP_SUMMARY + # echo '```' >> $GITHUB_STEP_SUMMARY + # cat ./lychee-report.txt >> $GITHUB_STEP_SUMMARY + # echo '```' >> $GITHUB_STEP_SUMMARY + + - name: Provide helpful failure message + if: failure() + run: | + echo "::error::Link check failed! Please review the broken links reported above." + echo "" + echo "If certain links are valid but fail due to:" + echo "- CAPTCHA challenges" + echo "- IP blocking" + echo "- Authentication requirements" + echo "- Rate limiting" + echo "" + echo "Consider adding them to .lycheeignore to bypass future checks." + echo "Format: Add one URL pattern per line" + exit 1 From 760b6a22c11371506bd4620fd5124d1a836c0f28 Mon Sep 17 00:00:00 2001 From: brossetti1 Date: Mon, 24 Feb 2025 11:53:45 -0500 Subject: [PATCH 2/4] removing unused config --- .github/workflows/lychee-cron.yml | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/.github/workflows/lychee-cron.yml b/.github/workflows/lychee-cron.yml index bbacfe16e27..fb1757a4a29 100644 --- a/.github/workflows/lychee-cron.yml +++ b/.github/workflows/lychee-cron.yml @@ -36,18 +36,8 @@ jobs: --format detailed './**/*.md' './**/*.html' - output: ./lychee-report.txt continue-on-error: true - # looks like we dont need to do this? - # - name: Add Lychee Report to Job Summary - # if: always() - # run: | - # echo "### Lychee Report" >> $GITHUB_STEP_SUMMARY - # echo '```' >> $GITHUB_STEP_SUMMARY - # cat ./lychee-report.txt >> $GITHUB_STEP_SUMMARY - # echo '```' >> $GITHUB_STEP_SUMMARY - - name: Provide helpful failure message if: failure() run: | From 71b8d42e1c9758d9d11014e370bf0df7ca6e8088 Mon Sep 17 00:00:00 2001 From: Paul Wackerow <54227730+wackerow@users.noreply.github.com> Date: Tue, 8 Jul 2025 19:59:52 -0700 Subject: [PATCH 3/4] patch: match only markdown --- .github/workflows/lychee-cron.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/lychee-cron.yml b/.github/workflows/lychee-cron.yml index fb1757a4a29..7f896317ecc 100644 --- a/.github/workflows/lychee-cron.yml +++ b/.github/workflows/lychee-cron.yml @@ -35,7 +35,6 @@ jobs: --include '^https?://' --format detailed './**/*.md' - './**/*.html' continue-on-error: true - name: Provide helpful failure message From a9d67e53c6185992863f38dc65833ada9a00a679 Mon Sep 17 00:00:00 2001 From: Paul Wackerow <54227730+wackerow@users.noreply.github.com> Date: Tue, 8 Jul 2025 20:00:29 -0700 Subject: [PATCH 4/4] chore: remove on pull_request trigger monthly cron job, manually dispatchable --- .github/workflows/lychee-cron.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/lychee-cron.yml b/.github/workflows/lychee-cron.yml index 7f896317ecc..d1c78dff7ad 100644 --- a/.github/workflows/lychee-cron.yml +++ b/.github/workflows/lychee-cron.yml @@ -1,7 +1,6 @@ name: Check Links In Public Directory on: - pull_request: schedule: - cron: "0 0 1 * *" # Monthly run on the 1st day of every month at midnight UTC workflow_dispatch: