.github: Add Dependabot.yml, update actions (#171)

This commit is contained in:
Cynthia Fox 2023-05-29 11:15:13 -04:00 committed by GitHub
parent b0a6a63034
commit 1e5780c395
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 29 additions and 9 deletions

6
.github/dependabot.yml vendored Normal file
View file

@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: ".github/workflows"
schedule:
interval: "daily"

View file

@ -10,16 +10,29 @@ jobs:
linkChecker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Restore lychee cache
uses: actions/cache@v3
with:
path: .lycheecache
key: cache-lychee-${{github.sha}}
restore-keys: cache-lychee-
- uses: actions/checkout@v3
- name: lychee Link Checker
id: lychee
uses: lycheeverse/lychee-action@v1.5.4
uses: lycheeverse/lychee-action@v1
with:
args: "--cache --max-cache-age 1d --verbose --no-progress './**/*.md'"
fail: true
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Comment on failure
uses: peter-evans/create-or-update-comment@v1
uses: peter-evans/create-or-update-comment@v3
if: env.lychee_exit_code != 0
with:
issue-number: 73
body: |
A link check [failed](https://github.com/nix-community/awesome-nix/actions/runs/${{ github.run_id }}).
A link check [failed](https://github.com/nix-community/awesome-nix/actions/runs/${{github.run_id}}).
- name: Fail if there were link errors
run: exit ${{ env.lychee_exit_code }}
run: exit ${{env.lychee_exit_code}}

View file

@ -8,8 +8,9 @@ jobs:
Awesome_Lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0
- run: |
github_token=${{ secrets.GITHUB_TOKEN }} npx awesome-lint
- run: npx awesome-lint
env:
github_token: ${{secrets.GITHUB_TOKEN}}