-
Notifications
You must be signed in to change notification settings - Fork 32
55 lines (48 loc) · 1.93 KB
/
lint.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
49
50
51
52
53
54
55
name: Generic Linters (config files, etc)
on: [pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
# TODO: add editor config linter
# https://github.com/editorconfig-checker/editorconfig-checker#continuous-integration
general-linters:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: mszostok/[email protected]
with:
checks: 'files,duppatterns,syntax'
experimental_checks: 'notowned,avoid-shadowing'
- name: Validate codecov
run: |
# https://docs.codecov.io/docs/codecov-yaml curl, if response code ok then exit 0 otherwise exit 1
curl -s -o /dev/null -w "%{http_code}" --data-binary @.codecov.yml https://codecov.io/validate | grep --invert-match 200 && exit 1 || exit 0
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@master
with:
ignore_paths: ./contrib/scripts/txdecoder.sh
- name: Validate renovate
uses: rinchsan/[email protected]
with:
pattern: '.github/renovate.json' # Regular expression for filename to validate, default to *.json
- name: yaml-lint
uses: ibiqlik/action-yamllint@v3
id: yaml-lint
with:
config_file: .yamllint.yml
- uses: actions/upload-artifact@v4
if: steps.yaml-lint.outcome == 'success'
with:
name: yamllint-logfile
path: ${{ steps.yaml-lint.outputs.logfile }}
# TODO: reinstate lint
# - name: Download actionlint
# id: get_actionlint
# run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
# shell: bash
# - name: Check workflow files
# run: |
# echo "::add-matcher::.github/actionlint-matcher.json"
# ${{ steps.get_actionlint.outputs.executable }} -color
# shell: bash