mirror of
https://github.com/actions/python-versions.git
synced 2025-12-13 22:17:32 +00:00
Update macos-python-builder.psm1
This commit is contained in:
@@ -31,15 +31,20 @@ class macOSPythonBuilder : NixPythonBuilder {
|
|||||||
.SYNOPSIS
|
.SYNOPSIS
|
||||||
Prepare system environment by installing dependencies and required packages.
|
Prepare system environment by installing dependencies and required packages.
|
||||||
#>
|
#>
|
||||||
|
if ($this.Version -eq "3.7.17") {
|
||||||
# Ensure Homebrew is installed (in case it's not already available)
|
# Ensure Homebrew is installed (in case it's not already available)
|
||||||
if (-not (Test-Path "/usr/local/bin/brew")) {
|
if (-not (Test-Path "/usr/local/bin/brew")) {
|
||||||
Write-Host "Homebrew not found. Installing Homebrew..."
|
Write-Host "Homebrew not found. Installing Homebrew..."
|
||||||
Invoke-Expression -Command "/bin/bash -c \"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)\""
|
Invoke-Expression -Command "/bin/bash -c \"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)\""
|
||||||
|
# Once Homebrew is installed, install the dependencies
|
||||||
|
Write-Host "Installing dependencies: bzip2, readline, ncurses..."
|
||||||
|
Execute-Command -Command "brew install bzip2 readline ncurses"
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
Write-Host "Homebrew is already installed."
|
Write-Host "Homebrew is already installed."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
[void] Configure() {
|
[void] Configure() {
|
||||||
<#
|
<#
|
||||||
|
|||||||
Reference in New Issue
Block a user