Skip to content
This repository has been archived by the owner on Mar 13, 2024. It is now read-only.

Commit

Permalink
Rename lockfiles and dist after downloading for release
Browse files Browse the repository at this point in the history
  • Loading branch information
DominicOram committed Jan 8, 2024
1 parent 2d5de31 commit 35628bf
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/code.yml
Original file line number Diff line number Diff line change
Expand Up @@ -216,12 +216,16 @@ jobs:
- name: Download wheel and lockfiles
uses: actions/download-artifact@v4.1.0
with:
path: artifacts/
pattern: "*dist*"

- name: Rename lockfiles and dist
run: |
mv lockfiles-${{ env.CONTAINER_PYTHON }}-dist-${{ github.sha }} lockfiles
mv ${{ env.DIST_WHEEL_PATH }} dist
- name: Fixup blank lockfiles
# Github release artifacts can't be blank
run: for f in ${{ env.DIST_LOCKFILE_PATH }}/*; do [ -s $f ] || echo '# No requirements' >> $f; done
run: for f in lockfiles/*; do [ -s $f ] || echo '# No requirements' >> $f; done

- name: Github Release
# We pin to the SHA, not the tag, for security reasons.
Expand All @@ -230,8 +234,8 @@ jobs:
with:
prerelease: ${{ contains(github.ref_name, 'a') || contains(github.ref_name, 'b') || contains(github.ref_name, 'rc') }}
files: |
${{ env.DIST_WHEEL_PATH }}/*
${{ env.DIST_LOCKFILE_PATH }}/*
dist/*
lockfiles/*
generate_release_notes: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down

0 comments on commit 35628bf

Please sign in to comment.