Skip to content

Commit

Permalink
build: Use upload-artifacts v4 (#896)
Browse files Browse the repository at this point in the history
  • Loading branch information
jjbayer authored Feb 4, 2025
1 parent 07ad880 commit a25651f
Showing 1 changed file with 27 additions and 6 deletions.
33 changes: 27 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,13 @@ jobs:
# consumed by cargo and setup.py to obtain the target dir
CARGO_BUILD_TARGET: ${{ matrix.target }}

- uses: actions/upload-artifact@v3.1.1
- uses: actions/upload-artifact@v4
with:
name: ${{ github.sha }}
name: artifact-macos-${{ matrix.target }}
path: py/dist/*
if-no-files-found: "error"
# since this artifact will be merged, compression is not necessary
compression-level: "0"

python-wheel-linux:
strategy:
Expand All @@ -63,10 +66,13 @@ jobs:
name: Build in Docker (x86_64)
run: make wheel-manylinux IMAGE=quay.io/pypa/"$MANYLINUX_VERSION"_x86_64

- uses: actions/upload-artifact@v3.1.1
- uses: actions/upload-artifact@v4
with:
name: ${{ github.sha }}
name: artifact-linux-${{ matrix.build-arch }}
path: py/dist/*
if-no-files-found: "error"
# since this artifact will be merged, compression is not necessary
compression-level: "0"

sdist:
name: Python sdist
Expand All @@ -81,7 +87,22 @@ jobs:

- run: make sdist

- uses: actions/upload-artifact@v3.1.1
- uses: actions/upload-artifact@v4
with:
name: ${{ github.sha }}
name: artifact-sdist
path: py/dist/*
if-no-files-found: "error"
# since this artifact will be merged, compression is not necessary
compression-level: "0"

merge:
name: Create Release Artifact
runs-on: ubuntu-latest
needs: [python-wheel-linux, python-wheel-mac, sdist]
steps:
- uses: actions/upload-artifact/merge@v4
with:
# Craft expects release assets from github to be a single artifact named after the sha.
name: ${{ github.sha }}
pattern: artifact-*
delete-merged: true

0 comments on commit a25651f

Please sign in to comment.