Skip to content

CI

CI #1552

Workflow file for this run

name: CI
on:
push:
branches:
- master
- "v*"
tags:
- "v*"
pull_request:
schedule:
- cron: '0 3 * * *' # daily, at 3am
jobs:
tests:
strategy:
fail-fast: true
matrix:
python-version:
- "3.12"
- "3.11"
- "3.10"
- "3.9"
- "3.8"
numpy:
- true
- false
name: "Tests (Python v${{ matrix.python-version }}, NumPy: ${{ matrix.numpy }})"
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- run: pip install -r requirements.txt
- run: pip install -r numpy-requirements.txt
if: matrix.numpy == true
- run: pytest -v --cov=utm --color=yes
release:
needs: tests
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
name: Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- run: python setup.py sdist
- uses: pypa/gh-action-pypi-publish@v1.8.11
with:
user: __token__
password: ${{ secrets.PYPI_TOKEN }}