From 9378641fb453aeb73eacede788040bdabe84ae05 Mon Sep 17 00:00:00 2001 From: Mikhail Timofeev <48208649+miketimofeev@users.noreply.github.com> Date: Sat, 27 Feb 2021 11:45:49 +0300 Subject: [PATCH] [macOS] Stick to go 1.15 (#2795) --- images/macos/provision/configuration/environment/bashrc | 1 - images/macos/provision/core/commonutils.sh | 3 +++ images/macos/toolsets/toolset-10.14.json | 2 +- images/macos/toolsets/toolset-10.15.json | 2 +- images/macos/toolsets/toolset-11.0.json | 2 +- 5 files changed, 6 insertions(+), 4 deletions(-) diff --git a/images/macos/provision/configuration/environment/bashrc b/images/macos/provision/configuration/environment/bashrc index 41479806e..bea64c7e2 100644 --- a/images/macos/provision/configuration/environment/bashrc +++ b/images/macos/provision/configuration/environment/bashrc @@ -16,7 +16,6 @@ export RUNNER_TOOL_CACHE=$HOME/hostedtoolcache export PATH=/Library/Frameworks/Mono.framework/Versions/Current/Commands:$PATH export PATH=$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools:$ANDROID_NDK_HOME:$PATH -export PATH=/usr/local/go/bin:$PATH export PATH=/usr/local/bin:/usr/local/sbin:~/bin:~/.yarn/bin:$PATH export PATH="/usr/local/opt/curl/bin:$PATH" export PATH="/usr/local/opt/ruby@2.7/bin:$PATH" diff --git a/images/macos/provision/core/commonutils.sh b/images/macos/provision/core/commonutils.sh index a13f6a7d1..9a0376923 100644 --- a/images/macos/provision/core/commonutils.sh +++ b/images/macos/provision/core/commonutils.sh @@ -19,6 +19,9 @@ if is_Less_Catalina; then echo "export USE_BAZEL_VERSION=${USE_BAZEL_VERSION}" >> "${HOME}/.bashrc" fi +# Create a symlink for Go 1.15 to preserve backward compatibility +ln -sf $(brew --prefix go@1.15)/bin/go /usr/local/bin/go + # Invoke bazel to download bazel version via bazelisk bazel diff --git a/images/macos/toolsets/toolset-10.14.json b/images/macos/toolsets/toolset-10.14.json index b8272a20f..317f7add5 100644 --- a/images/macos/toolsets/toolset-10.14.json +++ b/images/macos/toolsets/toolset-10.14.json @@ -242,7 +242,7 @@ "gh", "gnupg", "gnu-tar", - "go", + "go@1.15", "helm", "libpq", "llvm", diff --git a/images/macos/toolsets/toolset-10.15.json b/images/macos/toolsets/toolset-10.15.json index cd498aebe..36b27e6c1 100644 --- a/images/macos/toolsets/toolset-10.15.json +++ b/images/macos/toolsets/toolset-10.15.json @@ -187,7 +187,7 @@ "gh", "gnupg", "gnu-tar", - "go", + "go@1.15", "helm", "libpq", "llvm", diff --git a/images/macos/toolsets/toolset-11.0.json b/images/macos/toolsets/toolset-11.0.json index f5d52f771..e91513c37 100644 --- a/images/macos/toolsets/toolset-11.0.json +++ b/images/macos/toolsets/toolset-11.0.json @@ -120,7 +120,7 @@ "gh", "gnupg", "gnu-tar", - "go", + "go@1.15", "helm", "libpq", "llvm",