Skip to content

Clean up

Clean up #3

Workflow file for this run

name: wheels
on:
workflow_dispatch:
push:
tags:
- "*"
jobs:
create_release:
name: Create release
runs-on: ubuntu-latest
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
steps:
- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ github.ref }}
draft: false
prerelease: false
build_macos:
name: "macos build: ${{ matrix.arch }}"
runs-on: macos-latest
needs: create_release # we need to know the upload URL
strategy:
fail-fast: true
steps:
- uses: actions/checkout@v3
- name: venv
run: |
python3 -m venv .venv
.venv/bin/pip3 install --upgrade pip
- name: build
id: macos_wheel
run: |
.venv/bin/pip3 wheel .
echo "wheel=$(ls *.whl)" > ${GITHUB_OUTPUT}
- name: upload
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ needs.create_release.outputs.upload_url }}
asset_path: ${{ steps.macos_wheel.outputs.wheel }}
asset_name: ${{ steps.macos_wheel.outputs.wheel }}
asset_content_type: application/octet-stream