Skip to content

Workflow file for this run

name: Python Package using Mamba
on:
pull_request:
push:
branches:
- main
paths:
- ".github/workflows/package.yml"
- "environment-cpu.yml"
- "setup.cfg"
jobs:
get-python-versions:
runs-on: ubuntu-latest
outputs:
python-matrix: ${{ steps.get-python-versions-action.outputs.latest-python-versions }}
steps:
- uses: snok/latest-python-versions@v1
id: get-python-versions-action
with:
min-version: "3.11"
include-prereleases: false
build-linux:
needs: get-python-versions
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ${{ fromJson(needs.get-python-versions.outputs.python-matrix) }}
environment-file: [environment-cpu.yml]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Conda environment from `${{ matrix.environment-file}}` with Micromamba
uses: mamba-org/setup-micromamba@v1
with:
environment-file: ${{ matrix.environment-file }}
init-shell: >-
bash
zsh
cache-environment: true
post-cleanup: "all"