From ee5497b493ebd1ceea2275dc540ba68fce01660e Mon Sep 17 00:00:00 2001 From: moisseev Date: Fri, 10 May 2024 17:02:38 +0300 Subject: [PATCH] Split local and external links check --- .github/workflows/main.yml | 29 ++++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 29fb96039..81d5dd817 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -12,7 +12,7 @@ jobs: - run: ./node_modules/.bin/eslint ./ - run: ./node_modules/.bin/stylelint ./**/*.css ./**/*.html ./**/*.js - build-and-check-links: + build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -22,14 +22,37 @@ jobs: mkdir -p _site-root ln -s ../_site/ _site-root/${{ github.event.repository.name }} - - name: Check broken links + local-links-check: + runs-on: ubuntu-latest + needs: build + steps: + - name: Check broken local links uses: ruzickap/action-my-broken-link-checker@v2 with: url: https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }} pages_path: ./_site-root/ cmd_params: > --buffer-size=8192 --color=always --skip-tls-verification + --include="^https://${{ github.repository_owner }}[.]github[.]io/${{ github.event.repository.name }}/" +# --include="^https://rspamd[.]com/${{ github.event.repository.name }}/" + --exclude="^https://github[.]com/rspamd/rspamd[.]com/edit/master/" + --exclude="^https://${{ github.repository_owner }}[.]github[.]io/${{ github.event.repository.name }}/(doc/lua/((lua|rspamd)_.+|ucl)[.]html(#.+)?|.*#top)$" +# --exclude="^https://rspamd[.]com/${{ github.event.repository.name }}/." + debug: true + + external-links-check: + runs-on: ubuntu-latest + needs: build + steps: + - name: Check broken external links + uses: ruzickap/action-my-broken-link-checker@v2 + with: + url: https://${{ github.repository_owner }}.github.io/${{ github.event.repository.name }} + pages_path: ./_site-root/ + cmd_params: > + --buffer-size=8192 --max-connections=10 --color=always --skip-tls-verification + --exclude="^https://${{ github.repository_owner }}[.]github[.]io/${{ github.event.repository.name }}/" + --exclude="^https://rspamd[.]com/${{ github.event.repository.name }}/" --exclude="^https://github[.]com/rspamd/rspamd[.]com/edit/master/" - --exclude="^https://${{ github.repository_owner }}[.]github[.]io/${{ github.event.repository.name }}/(doc/lua/((lua|rspamd)_.+|ucl)[.]html|.+[.]html#top)$" --exclude="^https://rspamd[.]com/${{ github.event.repository.name }}/." debug: true