diff --git a/images/macos/scripts/build/install-aws-tools.sh b/images/macos/scripts/build/install-aws-tools.sh index db4565b73..168483862 100644 --- a/images/macos/scripts/build/install-aws-tools.sh +++ b/images/macos/scripts/build/install-aws-tools.sh @@ -10,9 +10,11 @@ echo "Installing aws..." awscliv2_pkg_path=$(download_with_retry "https://awscli.amazonaws.com/AWSCLIV2.pkg") sudo installer -pkg "$awscliv2_pkg_path" -target / -echo "Installing aws sam cli..." -brew tap aws/tap -brew_smart_install aws-sam-cli +if ! is_BigSur; then + echo "Installing aws sam cli..." + brew tap aws/tap + brew_smart_install aws-sam-cli +fi echo "Install aws cli session manager" brew install --cask session-manager-plugin diff --git a/images/macos/scripts/build/install-common-utils.sh b/images/macos/scripts/build/install-common-utils.sh index d9351a668..53a0af580 100644 --- a/images/macos/scripts/build/install-common-utils.sh +++ b/images/macos/scripts/build/install-common-utils.sh @@ -95,8 +95,10 @@ if is_Monterey; then echo "export PARALLELS_DMG_URL=$url" >> ${HOME}/.bashrc fi -# Install Azure DevOps extension for Azure Command Line Interface -az extension add -n azure-devops +if ! is_BigSur; then + # Install Azure DevOps extension for Azure Command Line Interface + az extension add -n azure-devops +fi # Invoke tests for all basic tools invoke_tests "BasicTools" diff --git a/images/macos/scripts/build/install-git.sh b/images/macos/scripts/build/install-git.sh index adc3ecccf..5a77ba3a4 100644 --- a/images/macos/scripts/build/install-git.sh +++ b/images/macos/scripts/build/install-git.sh @@ -11,13 +11,16 @@ brew_smart_install "git" git config --global --add safe.directory "*" -echo "Installing Git LFS" -brew_smart_install "git-lfs" -# Update global git config -git lfs install -# Update system git config -sudo git lfs install --system +if ! is_BigSur; then + echo "Installing Git LFS" + brew_smart_install "git-lfs" + + # Update global git config + git lfs install + # Update system git config + sudo git lfs install --system +fi echo "Disable all the Git help messages..." git config --global advice.pushUpdateRejected false diff --git a/images/macos/scripts/docs-gen/Generate-SoftwareReport.ps1 b/images/macos/scripts/docs-gen/Generate-SoftwareReport.ps1 index c73361aa6..c982e8efb 100644 --- a/images/macos/scripts/docs-gen/Generate-SoftwareReport.ps1 +++ b/images/macos/scripts/docs-gen/Generate-SoftwareReport.ps1 @@ -64,7 +64,7 @@ if ((-not $os.IsVentura) -and (-not $os.IsSonoma)) { if ((-not $os.IsVenturaArm64) -and (-not $os.IsSonomaArm64)) { $languageAndRuntime.AddToolVersion("Python3", $(Get-Python3Version)) } -if ((-not $os.IsVentura) -and (-not $os.IsSonoma)) { +if ((-not $os.IsVentura) -and (-not $os.IsSonoma) -and (-not $os.IsBigSur)) { $languageAndRuntime.AddToolVersion("R", $(Get-RVersion)) } $languageAndRuntime.AddToolVersion("Ruby", $(Get-RubyVersion)) @@ -120,7 +120,9 @@ $utilities.AddToolVersion("bazelisk", $(Get-BazeliskVersion)) $utilities.AddToolVersion("bsdtar", $(Get-BsdtarVersion)) $utilities.AddToolVersion("Curl", $(Get-CurlVersion)) $utilities.AddToolVersion("Git", $(Get-GitVersion)) -$utilities.AddToolVersion("Git LFS", $(Get-GitLFSVersion)) +if (-not $os.IsBigSur) { + $utilities.AddToolVersion("Git LFS", $(Get-GitLFSVersion)) +} $utilities.AddToolVersion("GitHub CLI", $(Get-GitHubCLIVersion)) $utilities.AddToolVersion("GNU Tar", $(Get-GnuTarVersion)) $utilities.AddToolVersion("GNU Wget", $(Get-WgetVersion)) @@ -165,10 +167,14 @@ if ((-not $os.IsVentura) -and (-not $os.IsSonoma)) { $tools.AddToolVersion("App Center CLI", $(Get-AppCenterCLIVersion)) } $tools.AddToolVersion("AWS CLI", $(Get-AWSCLIVersion)) -$tools.AddToolVersion("AWS SAM CLI", $(Get-AWSSAMCLIVersion)) +if (-not $os.IsBigSur) { + $tools.AddToolVersion("AWS SAM CLI", $(Get-AWSSAMCLIVersion)) +} $tools.AddToolVersion("AWS Session Manager CLI", $(Get-AWSSessionManagerCLIVersion)) -$tools.AddToolVersion("Azure CLI", $(Get-AzureCLIVersion)) -$tools.AddToolVersion("Azure CLI (azure-devops)", $(Get-AzureDevopsVersion)) +if (-not $os.IsBigSur) { + $tools.AddToolVersion("Azure CLI", $(Get-AzureCLIVersion)) + $tools.AddToolVersion("Azure CLI (azure-devops)", $(Get-AzureDevopsVersion)) +} $tools.AddToolVersion("Bicep CLI", $(Get-BicepVersion)) if ((-not $os.IsVentura) -and (-not $os.IsSonoma)) { $tools.AddToolVersion("Cabal", $(Get-CabalVersion)) @@ -221,6 +227,7 @@ $toolcache = $installedSoftware.AddHeader("Cached Tools") $toolcache.AddNodes($(Build-ToolcacheSection)) # Rust +if (-not $os.IsBigSur) { $rust = $installedSoftware.AddHeader("Rust Tools") $rust.AddToolVersion("Cargo", $(Get-RustCargoVersion)) $rust.AddToolVersion("Rust", $(Get-RustVersion)) @@ -236,6 +243,7 @@ if ((-not $os.IsVentura) -and (-not $os.IsSonoma)) { } $rustPackages.AddToolVersion("Clippy", $(Get-RustClippyVersion)) $rustPackages.AddToolVersion("Rustfmt", $(Get-RustfmtVersion)) +} # PowerShell $powerShell = $installedSoftware.AddHeader("PowerShell Tools") diff --git a/images/macos/scripts/tests/BasicTools.Tests.ps1 b/images/macos/scripts/tests/BasicTools.Tests.ps1 index 213e6fb93..7daa7f6b6 100644 --- a/images/macos/scripts/tests/BasicTools.Tests.ps1 +++ b/images/macos/scripts/tests/BasicTools.Tests.ps1 @@ -2,13 +2,13 @@ Import-Module "$PSScriptRoot/../helpers/Common.Helpers.psm1" $os = Get-OSVersion -Describe "Azure CLI" { +Describe "Azure CLI" -Skip:($os.IsBigSur) { It "Azure CLI" { "az -v" | Should -ReturnZeroExitCode } } -Describe "Azure DevOps CLI" { +Describe "Azure DevOps CLI" -Skip:($os.IsBigSur) { It "az devops" { "az devops -h" | Should -ReturnZeroExitCode } @@ -159,7 +159,7 @@ Describe "virtualbox" -Skip:($os.IsBigSur -or $os.IsVentura -or $os.IsSonoma) { } } -Describe "R" -Skip:($os.IsVentura -or $os.IsSonoma) { +Describe "R" -Skip:($os.IsVentura -or $os.IsSonoma -or $os.IsBigSur) { It "R" { "R --version" | Should -ReturnZeroExitCode } diff --git a/images/macos/scripts/tests/Common.Tests.ps1 b/images/macos/scripts/tests/Common.Tests.ps1 index 8a07c6180..6ce3c5349 100644 --- a/images/macos/scripts/tests/Common.Tests.ps1 +++ b/images/macos/scripts/tests/Common.Tests.ps1 @@ -43,7 +43,7 @@ Describe "AWS" { It "AWS CLI" { "aws --version" | Should -ReturnZeroExitCode } - It "AWS SAM CLI" { + It "AWS SAM CLI" -Skip:($os.IsBigSur) { "sam --version" | Should -ReturnZeroExitCode } diff --git a/images/macos/scripts/tests/Git.Tests.ps1 b/images/macos/scripts/tests/Git.Tests.ps1 index e88bf6bb5..f216baa0b 100644 --- a/images/macos/scripts/tests/Git.Tests.ps1 +++ b/images/macos/scripts/tests/Git.Tests.ps1 @@ -1,10 +1,12 @@ Import-Module "$PSScriptRoot/../helpers/Common.Helpers.psm1" +$os = Get-OSVersion + Describe "Git" { It "git is installed" { "git --version" | Should -ReturnZeroExitCode } - It "git lfs is installed" { + It "git lfs is installed" -Skip:($os.IsBigSur) { "git lfs version" | Should -ReturnZeroExitCode } } diff --git a/images/macos/scripts/tests/Rust.Tests.ps1 b/images/macos/scripts/tests/Rust.Tests.ps1 index b5c1c53fc..fda5475fb 100644 --- a/images/macos/scripts/tests/Rust.Tests.ps1 +++ b/images/macos/scripts/tests/Rust.Tests.ps1 @@ -2,7 +2,7 @@ Import-Module "$PSScriptRoot/../helpers/Common.Helpers.psm1" $os = Get-OSVersion -Describe "Rust" { +Describe "Rust" -Skip:($os.IsBigSur) { Context "Rust" { It "Rustup is installed" { "rustup --version" | Should -ReturnZeroExitCode diff --git a/images/macos/templates/macOS-11.pkr.hcl b/images/macos/templates/macOS-11.pkr.hcl index b136ccb4b..c9dc4256a 100644 --- a/images/macos/templates/macOS-11.pkr.hcl +++ b/images/macos/templates/macOS-11.pkr.hcl @@ -245,7 +245,6 @@ build { "${path.root}/../scripts/build/install-swiftlint.sh", "${path.root}/../scripts/build/install-openjdk.sh", "${path.root}/../scripts/build/install-aws-tools.sh", - "${path.root}/../scripts/build/install-rust.sh", "${path.root}/../scripts/build/install-gcc.sh", "${path.root}/../scripts/build/install-haskell.sh", "${path.root}/../scripts/build/install-cocoapods.sh", diff --git a/images/macos/toolsets/toolset-11.json b/images/macos/toolsets/toolset-11.json index 25f4f4059..cf26c25ea 100644 --- a/images/macos/toolsets/toolset-11.json +++ b/images/macos/toolsets/toolset-11.json @@ -195,7 +195,6 @@ "aliyun-cli", "ant", "aria2", - "azure-cli", "bazelisk", "carthage", "cmake", @@ -218,8 +217,7 @@ "zlib", "libxext", "libxft", - "tcl-tk", - "r" + "tcl-tk" ], "cask_packages": [ "julia"