forked from elanthia-online/dr-scripts
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (33 loc) · 865 Bytes
/
yamllint.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
name: Valid YAML syntax
on:
push:
paths:
- "data/*.yaml"
- "profiles/**.yaml"
pull_request:
paths:
- "data/*.yaml"
- "profiles/**.yaml"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
validate-yaml:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
with:
files: |
data/*.yaml
profiles/*.yaml
- name: Validate YAML file
if: steps.changed-files-excluded.outputs.any_changed == 'true'
run: |
for file in ${{ steps.changed-files.outputs.all_changed_files }}; do
yamllint -d relaxed -f parsable ${file}
done