Skip to content

Bump actions/checkout from 4 to 6 #122

Bump actions/checkout from 4 to 6

Bump actions/checkout from 4 to 6 #122

Workflow file for this run

name: Build and test
on:
push:
branches:
- "**"
pull_request:
jobs:
install_and_run:
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.repository
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
runs-on: "ubuntu-latest"
defaults:
run:
shell: bash -el {0}
steps:
- name: Clone
uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
environment-file: environment.yml
activate-environment: parsac
- run: pip install -v .
- run: python -c "import parsac; print(parsac.__version__)"
- uses: actions/checkout@v6
with:
repository: 'gotm-model/code'
ref: 'v6.0'
path: 'gotm'
submodules: 'recursive'
- run: python -m unittest discover -v -s test
- name: Build GOTM
run: |
conda install -c conda-forge fortran-compiler cmake netcdf-fortran ninja
cmake -S gotm -B gotm/build -G Ninja -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX
cmake --build gotm/build --target install
- name: Test optimization
run: |
cd examples
python optimize_gotm.py
- name: Test sensitivity analysis
run: |
cd examples
python sensitivity_gotm.py