Skip to content

Commit 4e55f83

Browse files
committed
fix: support ARM64 architecture in macOS PyPI release script
Detect macOS architecture (arm64 vs x86_64) and download the appropriate Miniconda version: - ARM64 (Apple Silicon): Miniconda3-latest-MacOSX-arm64.sh - x86_64 (Intel): Miniconda3-latest-MacOSX-x86_64.sh This ensures compatibility with both macos-latest (x86_64) and macos-14 (ARM64) GitHub Actions runners.
1 parent a51644e commit 4e55f83

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

release-pypi-macos.sh

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,14 @@ set -e
55
# this script has to be ran from a clean dockerfile
66

77
# Download and init conda
8-
MINICONDA_FILENAME=Miniconda3-latest-MacOSX-x86_64.sh
8+
# Detect architecture and set appropriate Miniconda filename
9+
ARCH=$(uname -m)
10+
if [ "$ARCH" = "arm64" ]; then
11+
MINICONDA_FILENAME=Miniconda3-latest-MacOSX-arm64.sh
12+
else
13+
MINICONDA_FILENAME=Miniconda3-latest-MacOSX-x86_64.sh
14+
fi
15+
916
curl -L -o $MINICONDA_FILENAME \
1017
"https://repo.continuum.io/miniconda/$MINICONDA_FILENAME"
1118
bash ${MINICONDA_FILENAME} -b -f -p $HOME/miniconda3

0 commit comments

Comments
 (0)