From 8cb014fb824c7a1840e967d26cf082e20accb287 Mon Sep 17 00:00:00 2001 From: Julien Jerphanion Date: Tue, 26 Nov 2024 15:51:07 +0100 Subject: [PATCH] fix: Also publish the Windows executable as an `.exe` file Signed-off-by: Julien Jerphanion --- fetch_release.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/fetch_release.py b/fetch_release.py index 306e50f..216c298 100644 --- a/fetch_release.py +++ b/fetch_release.py @@ -121,6 +121,12 @@ def get_micromamba(version, use_default_version): outfile = outdir / f"micromamba-{dplat}" shutil.copyfile(binary, outfile) + + # On Windows, we need to add the .exe extension explicitly + # so that the file is recognized as an executable. + if dplat == "win-64": + shutil.copyfile(binary, outdir / f"micromamba-{dplat}.exe") + shutil.copyfile(dlloc, outdir / f"micromamba-{dplat}{ext}") # compute the sha256