Skip to content

Create pylint.yml

Create pylint.yml #1

Workflow file for this run

name: Pylint
on:
push:
branches: [ "main" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pylint
- name: Analysing the code with pylint
run: |
# run pylint across multiple cpu cores to speed it up-
# https://pylint.pycqa.org/en/latest/user_guide/run.html?#parallel-execution to know more
pylint $(git ls-files '*.py') --fail-under=9.0 --rcfile=pylintrc --jobs=0