-
Notifications
You must be signed in to change notification settings - Fork 93
39 lines (32 loc) · 1.03 KB
/
pylint.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
name: Linting with Pylint
on: [pull_request]
jobs:
build:
runs-on: ubuntu-latest
name: Checks with pylint
steps:
- name: Install dependencies
run: sudo apt-get install libgirepository1.0-dev
- name: Checkout branch
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v44
with:
files: "**/*.py"
fetch-depth: 0
- name: Install python
if: steps.changed-files.output.any_changed == 'true'
uses: actions/setup-python@v3
with:
python-version: 3.x
- run: pip install --upgrade pip
if: steps.changed-files.output.any_changed == 'true'
- run: pip install .
if: steps.changed-files.output.any_changed == 'true'
- run: pip install pylint==2.16.*
if: steps.changed-files.output.any_changed == 'true'
- run: pylint --rcfile=pylintrc ${{ steps.changed-files.outputs.all_changed_files }}
if: steps.changed-files.output.any_changed == 'true'