-
Notifications
You must be signed in to change notification settings - Fork 1
80 lines (66 loc) · 2.08 KB
/
quality-checks.yml
File metadata and controls
80 lines (66 loc) · 2.08 KB
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
name: Quality Checks
on:
workflow_call:
secrets:
SONAR_TOKEN:
required: true
jobs:
quality_checks:
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v6.0.2
with:
ref: ${{ github.event.pull_request.head.sha || github.sha }}
fetch-depth: 0
- name: Install asdf
uses: asdf-vm/actions/setup@b7bcd026f18772e44fe1026d729e1611cc435d47
with:
asdf_version: 0.18.0
- name: Cache asdf
uses: actions/cache@v5
with:
path: |
~/.asdf
key: ${{ runner.os }}-asdf-${{ hashFiles('**/.tool-versions') }}
- name: Install asdf dependencies in .tool-versions
uses: asdf-vm/actions/install@b7bcd026f18772e44fe1026d729e1611cc435d47
with:
asdf_version: 0.18.0
env:
PYTHON_CONFIGURE_OPTS: --enable-shared
- name: Cache Virtualenv
uses: actions/cache@v5
id: cache-venv
with:
path: .venv
key: ${{ runner.os }}-venv-${{ hashFiles('pyproject.toml') }}
- name: Install Dependencies
if: steps.cache-venv.outputs.cache-hit != 'true'
run: make install
- name: Check licenses (Makefile)
run: |
make check-licenses
- name: Check licenses (Python)
run: make check-licenses
- name: Run code lint
run: make lint
- name: actionlint
uses: raven-actions/actionlint@v2
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@master
with:
ignore_paths: >-
*test*
.venv
node_modules
.git
- name: SonarQube
uses: actions/checkout@v6.0.2
with:
ref: ${{ github.event.pull_request.head.sha || github.sha }}
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: SonarQube Scan
uses: SonarSource/sonarqube-scan-action@c7ee0f9df90b7aa20e8dcf9695dcfe2e7da5b4f2
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}