generated from tweag/project
-
Notifications
You must be signed in to change notification settings - Fork 16
30 lines (27 loc) · 930 Bytes
/
lint.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
name: lint
on: [workflow_call]
jobs:
lint:
strategy:
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
timeout-minutes: 5
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Set up Poetry
uses: Gr1N/setup-poetry@v8
- uses: actions/cache@v2
with:
path: ~/.cache/pypoetry/virtualenvs
key: ${{ runner.os }}-poetry-lint-${{ hashFiles('poetry.lock') }}
- name: Install project
run: poetry install --no-interaction --sync --with=nox,lint
- name: Run linters on Python ${{ matrix.python-version }}
run: poetry run nox --no-venv --no-install --non-interactive -s lint