Skip to content

Commit

Permalink
BAU: Add Dependabot validation workflow
Browse files Browse the repository at this point in the history
Also, add a pre-commit hook to check that the GHA pinning is correct.
  • Loading branch information
whi-tw committed Jul 18, 2024
1 parent 5d9de2f commit c226d83
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/dependabot-validate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Validate Dependabot

on:
pull_request:
paths:
- ".github/dependabot.yml"
- ".github/workflows/dependabot-validate.yml"
jobs:
validate:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: marocchino/validate-dependabot@d8ae5c0d03dd75fbd0ad5f8ab4ba8101ebbd4b37 # v3.0.0
7 changes: 7 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,13 @@ repos:
hooks:
- id: actionlint

- repo: https://github.com/lalten/check-gha-pinning
rev: v1.1.0
hooks:
- id: check-gha-pinning
# Skip git check for now until subdirectory support is added (#1)
entry: env GHA_PINNING_SKIP_GIT_CHECK=1 check-gha-pinning

- repo: local
hooks:
- id: eslint
Expand Down

0 comments on commit c226d83

Please sign in to comment.