Skip to content

Add GitHub action to build GCPy environment and test installation #2

Add GitHub action to build GCPy environment and test installation

Add GitHub action to build GCPy environment and test installation #2

---
#
# GitHub action to build the GCPy environment with micromamba
# See: https://github.com/marketplace/actions/setup-micromamba
#
name: build-gcpy-environment
on:
push:
branches: [ "main", "dev" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "main", "dev" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9"]
steps:
- uses: mamba-org/setup-micromamba@v1.8.0
with:
micromamba-version: 'latest'
environment-file: docs/source/environment.yml
init-shell: bash
cache-environment: true
post-cleanup: 'all'
- name: Activate the GCPy environment
run: python -c "import gcpy"
- name: Run custom command in micromamba environment
run: python -m gcpy.examples.plotting.create_test_plot
shell: bash -el {0}