Skip to content

v2.2.3

v2.2.3 #8

Workflow file for this run

name: pip-install
on:
release:
types:
- published
jobs:
build:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
python: ['3.7', '3.8', '3.9']
steps:
- uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0
- uses: actions/setup-python@v4
name: Install Python
with:
activate-environment: vplanet
environment-file: environment.yml
python-version: ${{ matrix.python }}
- name: Build
run: |
python -m pip install -U pip pep517 twine setuptools_scm
python -m pep517.build .
- name: Test the sdist
run: |
python -m venv venv-sdist
python -m pip install astropy
venv-sdist/bin/python -m pip install dist/vspace*.tar.gz
venv-sdist/bin/python -c "import vspace; print(vspace.__version__)"
- name: Test the wheel
run: |
python -m venv venv-wheel
venv-wheel/bin/python -m pip install dist/vspace*.whl
venv-wheel/bin/python -c "import vspace; print(vspace.__version__)"
- uses: actions/upload-artifact@v3
with:
path: dist/*
upload_pypi:
needs: [build]
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
steps:
- uses: actions/download-artifact@v3
with:
name: artifact
path: dist
- uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.pypi_password }}