Skip to content

Commit

Permalink
Merge pull request #4 from lewisjared/final-release
Browse files Browse the repository at this point in the history
Clean up from #3
  • Loading branch information
lewisjared authored Apr 11, 2024
2 parents 6c4b4e1 + 8d46484 commit 047f32b
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 35 deletions.
6 changes: 0 additions & 6 deletions .github/release_template.md
Original file line number Diff line number Diff line change
@@ -1,7 +1 @@
## Announcements

* Announcement 1

## Changes

* Change 1
28 changes: 7 additions & 21 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,28 +9,9 @@ defaults:
shell: bash

jobs:
pre-deploy-checks:
name: Deploy to PyPI
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: ./.github/actions/setup
with:
python-version: "3.11"
venv-id: "deploy"
poetry-dependency-install-flags: "--all-extras"
- name: Run tests
run: |
poetry run pytest -r a src tests --doctest-modules
upload-all:
name: Upload if release
needs: [ pre-deploy-checks ]
name: Upload wheels and sdist to PyPI on release
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
environment: pypi
permissions:
id-token: write
Expand All @@ -40,9 +21,14 @@ jobs:
with:
python-version: "3.x"

- name: Log the tag
run: |
echo "Uploading assets from ${{ github.ref_name }} to pypi"
# Pull the released wheels and sdist tarball from the latest GH release
- uses: robinraju/[email protected]
with:
latest: true
tag: "${{ github.ref_name }}"
fileName: "*"
out-file-path: dist/

Expand Down
12 changes: 4 additions & 8 deletions .github/workflows/wheels.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,10 @@
name: Wheel builder

on:
# Not running wheel generation on every PR
# pull_request:
# # Comment the line below out to build wheels for a PR i.e. debugging
# pull_request:
push:
branches:
- main
tags:
- v*
branches: [ main ]
workflow_dispatch:
workflow_call:

Expand Down Expand Up @@ -63,13 +60,12 @@ jobs:
with:
platforms: all


- name: Build wheels
uses: pypa/[email protected]
env:
# configure cibuildwheel to build native archs ('auto'), and some
# emulated ones
# CIBW_ARCHS_LINUX: auto aarch64
CIBW_ARCHS_LINUX: auto aarch64
CIBW_ARCHS_WINDOWS: auto ARM64
# Explicitly specifying the Ninja Generator is required for gfortran builds on Windows
CMAKE_GENERATOR: Ninja
Expand Down
1 change: 1 addition & 0 deletions changelog/4.improvement.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Testing the build and release process for wheels

0 comments on commit 047f32b

Please sign in to comment.