Skip to content

fix version comparison when making examples, update precommit hooks, … #306

fix version comparison when making examples, update precommit hooks, …

fix version comparison when making examples, update precommit hooks, … #306

Workflow file for this run

# This workflow will install Python dependencies, run tests with a variety of Python versions
name: Python package
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install flit pytest pre-commit
flit install
- name: Copy documentation
run: |
cp -r docs $LD_LIBRARY_PATH/python${{ matrix.python-version }}/site-packages/plothist/docs
- name: Run pre-commit
run: |
pre-commit run --all-files
- name: Test with pytest
run: |
pytest