Skip to content

Merge pull request #10 from bin913/fix_run_test #15

Merge pull request #10 from bin913/fix_run_test

Merge pull request #10 from bin913/fix_run_test #15

Workflow file for this run

name: release-build-wheels

Check failure on line 1 in .github/workflows/release.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/release.yaml

Invalid workflow file

(Line: 66, Col: 17): Unexpected value 's'
on:
push:
tags:
- 'v*'
workflow_dispatch:
jobs:
build-wheels:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v5
- name: Pull manylinux2_28 image
run: docker pull quay.io/pypa/manylinux_2_28_x86_64
- name: Prepare directories
run: |
rm -rf ${{ runner.temp }}/wheelhouse ${{ runner.temp }}/build_temp
mkdir -p ${{ runner.temp }}/wheelhouse
mkdir -p ${{ runner.temp }}/build_temp
- name: Start manylinux builder container
run: |
container=$(docker run -td \
--name "flagblas_builder" \
-v ${{ github.workspace }}:/workspace \
-v ${{ runner.temp }}/build_temp:/workspace/build \
-v ${{ runner.temp }}/wheelhouse:/wheelhouse \
-w /workspace \
quay.io/pypa/manylinux_2_28_x86_64)
echo "CONTAINER=$container" >> $GITHUB_ENV
- name: Install build tools inside container
run: |
docker exec -t $CONTAINER bash -c "
set -e
/opt/python/cp38-cp38/bin/python -m pip install --upgrade pip setuptools wheel build
"
- name: Build wheel for Python 3.8
run: |
docker exec -t $CONTAINER bash -c "
set -e
/opt/python/cp38-cp38/bin/python -m build --wheel --outdir /wheelhouse
"
- name: Upload wheel as artifact
uses: actions/upload-artifact@v5
with:
name: built-wheel-${{ github.ref_name }}
path: ${{ runner.temp }}/wheelhouse/*.whl
- name: Cleanup container
if: always()
run: docker rm -f $CONTAINER
publish:
needs: build-wheels
runs-on: ubuntu-latest
environment: pypi
permissions:
id-token: s
steps:
- name: Checkout code
uses: actions/checkout@v5
- name: Download built wheel
uses: actions/download-artifact@v5
with:
name: built-wheel-${{ github.ref_name }}
path: dist
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__