Skip to content

Commit

Permalink
Merge pull request #50 from Hind-M/set_pre_release
Browse files Browse the repository at this point in the history
Handle prerelease
  • Loading branch information
JohanMabille authored Jul 17, 2024
2 parents 66edd07 + 7596780 commit bf019a2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ jobs:
if: steps.fetch-release.outputs.MICROMAMBA_NEW_VERSION == 'true'
with:
name: "micromamba ${{ steps.fetch-release.outputs.MICROMAMBA_VERSION }}"
prerelease: ${{ steps.fetch-release.outputs.MICROMAMBA_NEW_PRERELEASE == 'true' }}
body: |
Release artifacts for micromamba ${{ steps.fetch-release.outputs.MICROMAMBA_VERSION }}, mirrored from conda-forge.
The full changelog can be found [here](https://github.com/mamba-org/mamba/releases).
Expand Down
5 changes: 5 additions & 0 deletions fetch_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,11 @@ def get_micromamba(version, use_default_version):
with open(shafile, "w") as f:
f.write(sha256.hexdigest())

if (v := Version(version)).is_devrelease or v.is_prerelease:
set_output("MICROMAMBA_NEW_PRERELEASE", "true")
else:
set_output("MICROMAMBA_NEW_PRERELEASE", "false")

set_output("MICROMAMBA_NEW_VERSION", "true")
set_output("MICROMAMBA_VERSION", f"{version}-{build_number}")

Expand Down

0 comments on commit bf019a2

Please sign in to comment.