From 58ab5eea89f1c413f3075dbe6bc59bb9be3c34bf Mon Sep 17 00:00:00 2001 From: Tim Hockin Date: Tue, 11 Jan 2022 17:07:11 -0800 Subject: [PATCH] Remove some references to GOPATH --- hack/lint-dependencies.sh | 2 +- hack/pin-dependency.sh | 2 +- hack/update-internal-modules.sh | 2 +- hack/update-mocks.sh | 2 +- hack/update-netparse-cve.sh | 2 +- hack/update-vendor.sh | 2 +- hack/verify-golangci-lint.sh | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/hack/lint-dependencies.sh b/hack/lint-dependencies.sh index b9c983d2912..b8ca7498994 100755 --- a/hack/lint-dependencies.sh +++ b/hack/lint-dependencies.sh @@ -25,7 +25,7 @@ set -o pipefail KUBE_ROOT=$(dirname "${BASH_SOURCE[0]}")/.. source "${KUBE_ROOT}/hack/lib/init.sh" -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on # Explicitly set GOFLAGS to ignore vendor, since GOFLAGS=-mod=vendor breaks dependency resolution while rebuilding vendor export GOFLAGS=-mod=mod diff --git a/hack/pin-dependency.sh b/hack/pin-dependency.sh index 78ae0df3a1c..dc6c1c5cb91 100755 --- a/hack/pin-dependency.sh +++ b/hack/pin-dependency.sh @@ -25,7 +25,7 @@ set -o pipefail KUBE_ROOT=$(dirname "${BASH_SOURCE[0]}")/.. source "${KUBE_ROOT}/hack/lib/init.sh" -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on # Explicitly set GOFLAGS to ignore vendor, since GOFLAGS=-mod=vendor breaks dependency resolution while rebuilding vendor export GOFLAGS=-mod=mod diff --git a/hack/update-internal-modules.sh b/hack/update-internal-modules.sh index e623525ccb8..88db414479c 100755 --- a/hack/update-internal-modules.sh +++ b/hack/update-internal-modules.sh @@ -29,7 +29,7 @@ MODULES=( staging/src/k8s.io/kms/internal/plugins/_mock ) -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on # Detect problematic GOPROXY settings that prevent lookup of dependencies diff --git a/hack/update-mocks.sh b/hack/update-mocks.sh index 44c06826746..956aed1e4b3 100755 --- a/hack/update-mocks.sh +++ b/hack/update-mocks.sh @@ -23,7 +23,7 @@ set -o pipefail KUBE_ROOT=$(dirname "${BASH_SOURCE[0]}")/.. source "${KUBE_ROOT}/hack/lib/init.sh" -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on kube::golang::verify_go_version diff --git a/hack/update-netparse-cve.sh b/hack/update-netparse-cve.sh index e661a842da9..dd8af6141f2 100755 --- a/hack/update-netparse-cve.sh +++ b/hack/update-netparse-cve.sh @@ -34,7 +34,7 @@ kube::golang::verify_go_version export GOBIN="${KUBE_OUTPUT_BIN}" PATH="${GOBIN}:${PATH}" -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on # Install golangci-lint diff --git a/hack/update-vendor.sh b/hack/update-vendor.sh index 4e290ebaec9..31636b35c06 100755 --- a/hack/update-vendor.sh +++ b/hack/update-vendor.sh @@ -30,7 +30,7 @@ kube::golang::verify_go_version # Turn off workspaces until we are ready for them later export GOWORK=off -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on # Explicitly set GOFLAGS to ignore vendor, since GOFLAGS=-mod=vendor breaks dependency resolution while rebuilding vendor export GOFLAGS=-mod=mod diff --git a/hack/verify-golangci-lint.sh b/hack/verify-golangci-lint.sh index a644c6515c3..f9dfd104aec 100755 --- a/hack/verify-golangci-lint.sh +++ b/hack/verify-golangci-lint.sh @@ -128,7 +128,7 @@ done kube::golang::verify_go_version -# Explicitly opt into go modules, even though we're inside a GOPATH directory +# Explicitly opt into go modules export GO111MODULE=on # Install golangci-lint