Skip to content

Commit

Permalink
Add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
fpicot-sokube committed Jul 18, 2023
1 parent dc86ad9 commit 56a9518
Showing 1 changed file with 61 additions and 0 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# Workflow to build and test wheels
name: Wheel builder

on:
push:
branches:
- main
# Release branches
- "release-*"
pull_request:
branches:
- main
- "release-*"
# Manual run
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:

# Build the wheels for Linux, Windows and macOS for Python 3.8 and newer
build_wheels:
name: Build wheel for cp${{ matrix.python }}-${{ matrix.platform_id }}-${{ matrix.manylinux_image }}
runs-on: 'ubuntu-latest'
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Install pypa/build
run: >-
python3 -m
pip install
build
--user
- name: Build a binary wheel and a source tarball
run: >-
python3 -m
build
--wheel
--outdir dist/
- name: Store artifacts
uses: actions/upload-artifact@v3
with:
path: dist/*.whl

- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: dist/*.whl

0 comments on commit 56a9518

Please sign in to comment.