mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-20 06:29:50 +00:00
[macos] fix XCode simulator install behaviour (#7878)
* [macos] fix XCode simulator install behaviour
in 3929bc9f6e
was introduced regression: simulators were installed only for latest
XCode-14 instance. However, they should be installed for all XCode-14
instances.
let us revert that behaviour
* improve code readability by moving version comparison outside loop
* rework brew installation for ARM64
This commit is contained in:
@@ -8,12 +8,6 @@ echo "Installing Homebrew..."
|
||||
HOMEBREW_INSTALL_URL="https://raw.githubusercontent.com/Homebrew/install/master/install.sh"
|
||||
/bin/bash -c "$(curl -fsSL ${HOMEBREW_INSTALL_URL})"
|
||||
|
||||
git clone https://github.com/Homebrew/homebrew-cask $(brew --repository)/Library/Taps/homebrew/homebrew-cask --origin=origin --template= --config core.fsmonitor=false --depth 1
|
||||
git clone https://github.com/Homebrew/homebrew-core $(brew --repository)/Library/Taps/homebrew/homebrew-core --origin=origin --template= --config core.fsmonitor=false --depth 1
|
||||
|
||||
brew tap homebrew/cask
|
||||
brew tap homebrew/core
|
||||
|
||||
if [[ $arch == "arm64" ]]; then
|
||||
/opt/homebrew/bin/brew update
|
||||
/opt/homebrew/bin/brew upgrade
|
||||
@@ -22,6 +16,12 @@ if [[ $arch == "arm64" ]]; then
|
||||
eval "$(/opt/homebrew/bin/brew shellenv)"
|
||||
fi
|
||||
|
||||
git clone https://github.com/Homebrew/homebrew-cask $(brew --repository)/Library/Taps/homebrew/homebrew-cask --origin=origin --template= --config core.fsmonitor=false --depth 1
|
||||
git clone https://github.com/Homebrew/homebrew-core $(brew --repository)/Library/Taps/homebrew/homebrew-core --origin=origin --template= --config core.fsmonitor=false --depth 1
|
||||
|
||||
brew tap homebrew/cask
|
||||
brew tap homebrew/core
|
||||
|
||||
echo "Disabling Homebrew analytics..."
|
||||
brew analytics off
|
||||
|
||||
|
||||
Reference in New Issue
Block a user