Skip to content

LinkCheck - All files #50

LinkCheck - All files

LinkCheck - All files #50

Workflow file for this run

name: "LinkCheck - All files"
on:
schedule:
- cron: "0 5 * * 2"
jobs:
run-checks:
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: LinkCheck
id: run_tests
run: |
make linkcheck > logs.txt || echo "OUTPUT=$(grep -E "broken" logs.txt | tr '\n' '@' | sed 's/@/<br>/g' | sed 's/broken/*\*`broken`\*\*/g' | sed $'s/\e\\[[0-9;:]*[a-zA-Z]//g')" >> $GITHUB_ENV
- name: Create Issue
if: "${{ env.RES != '' }}"
uses: dblock/create-a-github-issue@v3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
filename: .github/ISSUE_TEMPLATE/linkcheck_report.md
- name: Create Issue
if: "${{ env.OUTPUT != '' }}"
uses: dblock/create-a-github-issue@v3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
filename: .github/ISSUE_TEMPLATE/linkcheck_report.md
- run: echo {{ env.OUTPUT }}