From 60819a7dff84c0234a6009d860acf6fc57081509 Mon Sep 17 00:00:00 2001 From: ViViDboarder Date: Wed, 13 Dec 2023 09:24:26 -0800 Subject: [PATCH] Language Servers: Fix go detection maybe_run only checks the first arugment, which for go modules would have been `env`. Since `env` exists, it would always attempt to do the `go install` command, regardless of whether or not go exists. This patch moves the env to an exported variable rather than being passed inline. --- install-language-servers.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/install-language-servers.sh b/install-language-servers.sh index ec679b3..23dfb6d 100755 --- a/install-language-servers.sh +++ b/install-language-servers.sh @@ -102,7 +102,8 @@ function install_language_servers() { # Go if want_lang go ;then - maybe_run env GO111MODULE=on go install golang.org/x/tools/gopls@latest + export GO111MODULE=on + maybe_run go install golang.org/x/tools/gopls@latest fi echo ""