-
Notifications
You must be signed in to change notification settings - Fork 3.1k
48 lines (43 loc) · 1.45 KB
/
github-schema-validation.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: '.github schema check'
on:
workflow_dispatch:
push:
branches:
- master
paths:
- '.github/dependabot.yml'
- '.github/actions/*/action.yml'
- '.github/workflows/*.yml'
pull_request:
paths:
- '.github/dependabot.yml'
- '.github/actions/*/action.yml'
- '.github/workflows/*.yml'
jobs:
github-schemas:
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/[email protected]
with:
fetch-depth: 1
- name: '.github/dependabot.yml'
if: ${{ hashFiles('.github/dependabot.yml') != '' }}
uses: cardinalby/schema-validator-action@v3
with:
file: '.github/dependabot.yml'
schema: 'https://json.schemastore.org/dependabot-2.0.json'
mode: 'lax' # We really just want allowUnusedKeywords: true
- name: '.github/actions'
if: ${{ hashFiles('.github/actions/*/action.yml') != '' }}
uses: cardinalby/schema-validator-action@v3
with:
file: '.github/actions/*/action.yml'
schema: 'https://json.schemastore.org/github-action.json'
- name: '.github/workflows'
if: ${{ hashFiles('.github/workflows/*.yml') != '' }}
uses: cardinalby/schema-validator-action@v3
with:
file: '.github/workflows/*.yml'
schema: 'https://json.schemastore.org/github-workflow.json'
mode: 'lax' # https://github.com/SchemaStore/schemastore/issues/3102