Update links.yml

This commit is contained in:
Jake Henning 2021-12-28 16:35:44 +02:00 committed by GitHub
parent 4003bff771
commit 0f1a670a73
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -24,20 +24,21 @@ jobs:
- name: Find all markdown files
id: find_files
run: |
echo "::set-output name=files::$(find . -name '*.md' -type f | sed 's|^./||' | tr '\n' ' ')"
run: echo "MD_FILES=$(find . -name '*.md' -type f | sed 's|^./||' | tr '\n' ' ')" >> $GITHUB_ENV
- name: Link Checker
id: lychee
uses: lycheeverse/lychee-action@v1.2.0
with:
args: --verbose --no-progress ${{steps.find_files.outputs.files}}
format: json
output: /tmp/links.json
args: --verbose --no-progress $MD_FILES
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Read Markdown
if: ${{ steps.lychee.outputs.exit_code != 0 }}
run: echo "REPORT=$(jq -Rs '.' ./lychee/out.md)" >> $GITHUB_ENV
run: echo "REPORT=$(echo jq -Rs '```.```' /tmp/links.json)" >> $GITHUB_ENV
- name: Slack Notification
if: ${{ steps.lychee.outputs.exit_code != 0 }}