From 4fc7e5235229b8bdd499c5cb87ac26d6b3d91bcb Mon Sep 17 00:00:00 2001 From: Doctor Date: Wed, 12 Mar 2025 20:53:31 +0300 Subject: [PATCH] ci: add lint workflow --- .github/workflows/lint.yaml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/lint.yaml diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml new file mode 100644 index 0000000..2b1fd33 --- /dev/null +++ b/.github/workflows/lint.yaml @@ -0,0 +1,31 @@ +name: Lint +on: [push, pull_request] +jobs: + lint: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + python-version: + - 3.12 + job: + - mypy . + - ruff format --check . + - ruff check . + + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} + + - name: Install uv + uses: astral-sh/setup-uv@v5 + with: + enable-cache: true + + - name: Install dependencies + run: uv sync --all-extras --all-groups + + - run: uv run ${{ matrix.job }}