Skip to content

Merge pull request #168 from qulacs/142-gate-ostream #50

Merge pull request #168 from qulacs/142-gate-ostream

Merge pull request #168 from qulacs/142-gate-ostream #50

Workflow file for this run

name: Wheel build
on:
push:
paths-ignore:
- ".devcontainer/**"
- ".vscode/**"
- "*.md"
branches:
- "main"
tags:
- "v*"
workflow_dispatch:
jobs:
wheel-build:
name: Python wheel build
strategy:
fail-fast: false
matrix:
os-arch: ["manylinux_x86_64"]
cibw-python: ["cp38", "cp39", "cp310", "cp311", "cp312"]
include:
- os-arch: "manylinux_x86_64"
os: "ubuntu-22.04"
- cibw-python: "cp38"
python-version: "3.8"
- cibw-python: "cp39"
python-version: "3.9"
- cibw-python: "cp310"
python-version: "3.10"
- cibw-python: "cp311"
python-version: "3.11"
- cibw-python: "cp312"
python-version: "3.12"
runs-on: ${{ matrix.os }}
env:
CIBW_BUILD: ${{ matrix.cibw-python }}-${{ matrix.os-arch }}
PYTHON: ${{ matrix.python-version }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Python dependencies
run: python -m pip install cibuildwheel twine
- name: Build wheels
run: python -m cibuildwheel --output-dir wheels
- name: Upload wheel to GitHub
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.cibw-python }}-${{ matrix.os-arch }}
path: ./wheels/*.whl
- name: Upload wheel data if the Git tag is set
run: python -m twine upload wheels/*.whl
if: ${{ contains(github.ref, 'tags/') }}
env:
TWINE_USERNAME: "__token__"
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN_SCALUQ }}