Skip to content

ci: split ci and build workflow #35

ci: split ci and build workflow

ci: split ci and build workflow #35

Workflow file for this run

name: ci
on:
push:
branches:
- main
tags:
- '*'
pull_request:
workflow_dispatch:
permissions:
contents: read
jobs:
quality:
name: ${{ matrix.os }} / ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}-latest
strategy:
fail-fast: false
matrix:
os: [Ubuntu, MacOS, Windows]
python-version: [3.8, 3.9, 3.10, 3.11, 3.12]
defaults:
run:
shell: bash
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 python environment
run: |
python -m pip install pipenv
python -m pipenv install -r requirements-dev.txt
- name: Lint
run: |
python -m pipenv shell
pre-commit run --all-files
- name: Build
uses: PyO3/maturin-action@v1
with:
command: develop
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: Test with coverage
run: |
python -m pipenv shell
cargo llvm-cov --lcov --output-path coverage.lcov
pytest --cov=bionic_writer --cov-report xml
- name: Publish Coverage
uses: codecov/codecov-action@v1
if: |
matrix.os == 'ubuntu-latest' &&
matrix.python-version == '3.10'