Skip to content

Modernize packaging and update to support pymc > v4 #60

Modernize packaging and update to support pymc > v4

Modernize packaging and update to support pymc > v4 #60

Workflow file for this run

name: Packaging
on:
release:
types:
- published
pull_request:
branches:
- main
env:
CIBW_BUILD: "cp38-* cp39-* cp310-*"
CIBW_SKIP: "*-win32 *musllinux* *i686*"
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
jobs:
# build_wheels:
# name: Build ${{ matrix.python-version }} wheels on ${{ matrix.os }}
# runs-on: ${{ matrix.os }}
# strategy:
# fail-fast: false
# matrix:
# os: [ubuntu-latest, macos-latest] # , windows-latest]
# steps:
# - uses: actions/checkout@v4
# with:
# fetch-depth: 0
# - uses: actions/setup-python@v3
# name: Install Python
# with:
# # Note: cibuildwheel builds for many Python versions beyond this one
# python-version: "3.9"
# - name: Install MSVC / Visual C++
# if: runner.os == 'Windows'
# uses: ilammy/msvc-dev-cmd@v1
# - name: Build wheels
# run: |
# python -m pip install cibuildwheel
# python -m cibuildwheel --output-dir wheelhouse
# - uses: actions/upload-artifact@v2
# with:
# path: ./wheelhouse/*.whl
build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v5
name: Install Python
with:
python-version: "3.9"
- name: Build sdist
run: |
python -m pip install build
python -m build --sdist
- uses: actions/upload-artifact@v2
with:
path: dist/*.tar.gz
upload_pypi:
# needs: [build_wheels, build_sdist]
needs: [build_sdist]
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
steps:
- uses: actions/download-artifact@v4
with:
name: artifact
path: dist
- uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.pypi_password }}
# To test: repository_url: https://test.pypi.org/legacy/