Skip to content

Commit

Permalink
Merge branch 'v3.0-alpha'
Browse files Browse the repository at this point in the history
  • Loading branch information
jlvdb committed Nov 20, 2024
2 parents f153dab + 5ae5218 commit 4f68be4
Showing 1 changed file with 22 additions and 66 deletions.
88 changes: 22 additions & 66 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.

name: Build wheels and sdist and upload to PyPI

on:
Expand All @@ -16,64 +8,28 @@ permissions:
contents: read

jobs:
build_linux_wheels:
name: Build wheels on standard linux
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Build wheels
uses: pypa/[email protected]
env:
CIBW_BUILD: "*manylinux*"
CIBW_SKIP: cp36* pp*

- uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl

build_sdist:
name: Build sdist and upload to PyPI
needs: build_linux_wheels
# Just need to build sdist on a single machine
deploy:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v3
with:
python-version: "3.10"

- name: Install dependencies
run: |
python -m pip install -U pip
pip install -U numpy setuptools
pip install -U .
- name: Download wheels
uses: actions/[email protected]
with:
path: ./wheels

- name: Build sdist
run: |
python setup.py sdist
ls -l dist
tar tvfz dist/yet_another_wizz-*.tar.gz
- name: Copy wheels
run: |
echo ls -l wheels
ls -l wheels
echo ls -l wheels/artifact
ls -l wheels/artifact
cp wheels/artifact/*.whl dist
echo ls -l dist
ls -l dist
- name: Publish package
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.x

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -U .
- name: Build the package
run: python -m build

- name: Publish package
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}

0 comments on commit 4f68be4

Please sign in to comment.