Change pushd $d; go ...; popd to go -C $d ...
Just an annoyance in reading these scripts.
This commit is contained in:
@@ -127,15 +127,13 @@ done
|
||||
|
||||
# Install golangci-lint
|
||||
echo "installing golangci-lint and logcheck plugin from hack/tools into ${GOBIN}"
|
||||
pushd "${KUBE_ROOT}/hack/tools" >/dev/null
|
||||
go install github.com/golangci/golangci-lint/cmd/golangci-lint
|
||||
if [ "${golangci_config}" ]; then
|
||||
# This cannot be used without a config.
|
||||
# This uses `go build` because `go install -buildmode=plugin` doesn't work
|
||||
# (on purpose: https://github.com/golang/go/issues/64964).
|
||||
go build -o "${GOBIN}/logcheck.so" -buildmode=plugin sigs.k8s.io/logtools/logcheck/plugin
|
||||
fi
|
||||
popd >/dev/null
|
||||
go -C "${KUBE_ROOT}/hack/tools" install github.com/golangci/golangci-lint/cmd/golangci-lint
|
||||
if [ "${golangci_config}" ]; then
|
||||
# This cannot be used without a config.
|
||||
# This uses `go build` because `go install -buildmode=plugin` doesn't work
|
||||
# (on purpose: https://github.com/golang/go/issues/64964).
|
||||
go -C "${KUBE_ROOT}/hack/tools" build -o "${GOBIN}/logcheck.so" -buildmode=plugin sigs.k8s.io/logtools/logcheck/plugin
|
||||
fi
|
||||
|
||||
if [ "${golangci_config}" ]; then
|
||||
# The relative path to _output/local/bin only works if that actually is the
|
||||
|
||||
Reference in New Issue
Block a user