Bump actions/download-artifact from 2 to 4.1.7 in /.github/workflows #39
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
push: | |
branches: | |
- "**" | |
tags: | |
- "v*" | |
jobs: | |
build_src_wheel: | |
name: Build source wheel | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@v2 | |
name: Install Python 3.9 | |
with: | |
python-version: 3.9 | |
- name: Update to latest pip | |
run: | | |
python -m pip install -U setuptools pip wheel | |
- name: Build wheel | |
run: | | |
python setup.py sdist -d wheelhouse | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: wheels | |
path: wheelhouse | |
build_plat_wheels: | |
strategy: | |
matrix: | |
os: ["ubuntu-latest", "windows-latest", "macos-latest"] | |
name: Build platform wheels on ${{ matrix.os }} | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@v2 | |
name: Install Python 3.9 | |
with: | |
python-version: 3.9 | |
- name: Install cibuildwheel | |
run: | | |
python -m pip install cibuildwheel~=2.0 | |
- name: Build wheel | |
run: | | |
python -m cibuildwheel --output-dir wheelhouse | |
env: | |
CIBW_BUILD: cp* | |
CIBW_ARCHS_MACOS: universal2 | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: wheels | |
path: ./wheelhouse | |
pypi_upload: | |
needs: [build_src_wheel, build_plat_wheels] | |
name: Upload wheels to pypi | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags') | |
steps: | |
- uses: actions/[email protected] | |
with: | |
name: wheels | |
path: dist | |
- name: Publish package to PyPI | |
uses: pypa/[email protected] | |
with: | |
user: __token__ | |
password: ${{ secrets.PYPI_TOKEN }} |