Skip to content
This repository was archived by the owner on Mar 25, 2025. It is now read-only.

Commit 6fac33f

Browse files
committed
On Linux, only delete Python installations with the same architecture.
This matches the macOS behavior and allows users to install both the free-threading and default builds at the same time.
1 parent 8dca029 commit 6fac33f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Diff for: installers/nix-setup-template.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ echo "Check if Python hostedtoolcache folder exist..."
2424
if [ ! -d $PYTHON_TOOLCACHE_PATH ]; then
2525
echo "Creating Python hostedtoolcache folder..."
2626
mkdir -p $PYTHON_TOOLCACHE_PATH
27-
elif [ -d $PYTHON_TOOLCACHE_VERSION_PATH ]; then
28-
echo "Deleting Python $PYTHON_FULL_VERSION"
29-
rm -rf $PYTHON_TOOLCACHE_VERSION_PATH
27+
elif [ -d $PYTHON_TOOLCACHE_VERSION_ARCH_PATH ]; then
28+
echo "Deleting Python $PYTHON_FULL_VERSION ($ARCH)"
29+
rm -rf $PYTHON_TOOLCACHE_VERSION_ARCH_PATH
3030
fi
3131

3232
echo "Create Python $PYTHON_FULL_VERSION folder"

0 commit comments

Comments
 (0)