forked from Cytomine-ULiege/Cytomine-python-client
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (33 loc) · 972 Bytes
/
code-quality.yaml
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: Code Quality
on:
pull_request:
branches:
- main
paths:
- "cytomine/**/*.py"
- "examples/**/*.py"
- "tests/**/*.py"
jobs:
check-lint:
runs-on: ubuntu-latest
steps:
- name: Set up the repository
uses: actions/checkout@v3
- name: Set up Python ${{ vars.PYTHON_VERSION }}
uses: actions/setup-python@v4
with:
python-version: ${{ vars.PYTHON_VERSION }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install pylint
- name: Check lint
run: pylint --output=lint.txt cytomine examples tests
- name: Upload lint report
if: ${{ always() }}
run: |
echo '# Lint report' >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
cat lint.txt >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY