50 lines
1.2 KiB
YAML
50 lines
1.2 KiB
YAML
name: CI Pipeline
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
matrix:
|
|
python-version: ["3.10", 3.11, 3.12, 3.13]
|
|
|
|
steps:
|
|
- name: Check out code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
python -m pip install -e .[dev]
|
|
if [ "${{ matrix.python-version }}" = "3.13" ]; then
|
|
python -m pip install cffconvert
|
|
fi
|
|
|
|
- name: Validate CITATION.cff
|
|
if: ${{ matrix.python-version == '3.13' }}
|
|
run: cffconvert --validate
|
|
|
|
- name: Prepare data and compile thermo database
|
|
run: |
|
|
python thermo_data/combine_data.py thermo_data/combined_data.yaml thermo_data/nasa9*.yaml thermo_data/nasa9*.xml
|
|
python thermo_data/compile_to_bin.py thermo_data/combined_data.yaml src/gaspype/data/therm_data.bin
|
|
|
|
- name: Lint code with flake8
|
|
run: flake8
|
|
|
|
- name: Type checking with mypy
|
|
run: mypy
|
|
|
|
- name: Run tests with pytest
|
|
run: pytest |