Skip to content

Add rye as a package manager. #16

Add rye as a package manager.

Add rye as a package manager. #16

Workflow file for this run

name: "Code Coverage"
on: [ push, pull_request ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ "3.11.3" ]
steps:
- uses: actions/checkout@v4
- uses: eifinger/setup-rye@v3
id: setup-rye
with:
enable-cache: true
cache-prefix: ${{ matrix.python-version }}
- name: Pin python-version ${{ matrix.python-version }}
if: steps.setup-rye.outputs.cache-hit != 'true'
run: rye pin ${{ matrix.python-version }}
- name: Install dependencies
if: steps.setup-rye.outputs.cache-hit != 'true'
run: |
rye sync --no-lock
- name: Cache pre-commit
uses: actions/cache@ab5e6d0c87105b4c9c2047343972218f562e4319 # v4.0.1
with:
path: ~/.cache/pre-commit
key: pre-commit-|${{ matrix.python-version }}|${{ hashFiles('.pre-commit-config.yaml') }}
- name: Lint
run: |
rye run pre-commit run --all-files
- name: Test
run: |
rye run pytest
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
file: ./htmlcov/index.html