-
Notifications
You must be signed in to change notification settings - Fork 2
40 lines (39 loc) · 1.09 KB
/
pylinting.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
name: pylinting
run-name: Python linting merged or pull-requested code.
on:
push:
branches:
- 'main'
pull_request:
types:
- opened
- edited
- reopened
- synchronize
jobs:
do_linting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Create pip requirements.
run: |
bash build/build_scripts/create_requirements.sh > requirements.txt &&
bash build/build_scripts/create_requirements.sh all >> requirements.txt &&
echo "pylint" >> requirements.txt
- name: Set up Python 3.9 .
uses: actions/setup-python@v4
with:
python-version: 3.9
cache: 'pip'
- name: Install Python dependencies.
run: |
pip install -r requirements.txt
- name: Linting the Python source code.
run: |
pylint --output-format=colorized --rc-file .pylintrc spatialprofilingtoolbox/ | tee linter_output.txt
- name: Upload linter results.
uses: actions/upload-artifact@v3
with:
name: pylint-results
path: linter_output.txt
if: ${{ always() }}