feat!: switch to uv #252
This file contains 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 Pipeline | |
"on": | |
push: | |
branches: [main] | |
pull_request: | |
paths: | |
- calcipy/** | |
- tests/** | |
- uv.lock | |
- pyproject.toml | |
jobs: | |
lint: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python-version: ["3.9"] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/setup | |
with: | |
os: ${{ matrix.os }} | |
python-version: ${{ matrix.python-version }} | |
- name: Run static linters | |
run: uv run calcipy-lint lint.check | |
test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [macos-latest, windows-latest] | |
python-version: ["3.9"] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/setup | |
with: | |
os: ${{ matrix.os }} | |
python-version: ${{ matrix.python-version }} | |
- name: Run test | |
run: uv run calcipy-test test.pytest | |
typecheck: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
python-version: ["3.9"] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/setup | |
with: | |
os: ${{ matrix.os }} | |
python-version: ${{ matrix.python-version }} | |
- name: Run typecheck | |
run: uv run calcipy-types types.mypy | |
# Based on: https://github.com/jakebailey/pyright-action/issues/10#issuecomment-1455220629 | |
- name: Add uv Python to Path | |
run: echo ".venv/bin" >> $GITHUB_PATH | |
- uses: jakebailey/pyright-action@v2 |