refactor: add more lint rules #172
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
jobs: | |
prepare: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Create matrix | |
id: create_matrix | |
uses: fabiocaccamo/create-matrix-action@v3 | |
with: | |
matrix: | | |
python-version {3.9}, django-version {4.2} | |
python-version {3.10}, django-version {4.2,5.0,5.1} | |
python-version {3.11}, django-version {4.2,5.0,5.1} | |
python-version {3.12}, django-version {4.2,5.0,5.1} | |
python-version {3.13}, django-version {5.1} | |
outputs: | |
matrix: ${{ steps.create_matrix.outputs.matrix }} | |
test: | |
needs: prepare | |
strategy: | |
fail-fast: false | |
matrix: | |
include: ${{ fromJson(needs.prepare.outputs.matrix) }} | |
name: "Python ${{ matrix.python-version }} + Django ${{ matrix.django-version }}" | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- run: pip install -e '.[dev]' | |
- run: pip install "Django==${{ matrix.django-version }}.*" | |
- run: make test | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.13" | |
- run: pip install -e '.[dev]' | |
- run: make lint |