Check links #148
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 6 * * 1' | |
name: Check links | |
jobs: | |
link-checker: | |
name: Check links | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- run: echo '/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin' >> $GITHUB_PATH | |
- run: brew install muffet | |
- name: Check | |
run: muffet --header 'user-agent:Curl' --ignore-fragments --json --accepted-status-codes 200..300,301,403 https://gitdocumentatie.logius.nl/publicatie/scripts/paths.html > muffet.json | |
continue-on-error: true | |
- name: Report | |
run: python ./scripts/muffet-json.py | |
- name: Send mail | |
uses: dawidd6/action-send-mail@v3 | |
with: | |
server_address: smtp.gmail.com | |
server_port: 465 | |
secure: true | |
username: ${{secrets.MAIL_USERNAME}} | |
password: ${{secrets.MAIL_PASSWORD}} | |
subject: Broken links on gitdocumentatie | |
to: ${{secrets.MAIL_RECIPIENTS}} | |
from: Standaarden Bot | |
html_body: file://links.md | |
ignore_cert: true | |
convert_markdown: true |