Skip to content

Minor fixes

Minor fixes #50

Workflow file for this run

name: Release
on:
pull_request:
push:
branches:
- main
release:
types:
- published
jobs:
release:
name: Upload release to PyPI
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/cmocean
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- name: Install dependencies
run: |
python -m pip install -U build check-manifest pip pytest setuptools setuptools-scm twine
- name: Build distributions
run: python -m build --sdist --wheel . --outdir dist
- name: CheckFiles
run: |
ls dist
check-manifest --verbose
- name: Test wheels
run: |
cd dist
python -m twine check *
python -m pip install *.whl
cp --recursive ../tests .
python -m pytest -rxs tests
- name: Publish to PyPI
if: success() && github.event_name == 'release'
uses: pypa/gh-action-pypi-publish@release/v1