Skip to content

Commit

Permalink
manually install golicense from the last release
Browse files Browse the repository at this point in the history
  • Loading branch information
tzneal committed Apr 11, 2022
1 parent ccba324 commit 87435ea
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion hack/toolchain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,23 @@ tools() {
go install github.com/golangci/golangci-lint/cmd/[email protected]
go install github.com/google/[email protected]
go install github.com/mikefarah/yq/[email protected]
go install github.com/mitchellh/[email protected]
go install github.com/norwoodj/helm-docs/cmd/[email protected]
go install github.com/onsi/ginkgo/[email protected]
go install sigs.k8s.io/controller-runtime/tools/[email protected]
go install sigs.k8s.io/controller-tools/cmd/[email protected]
go install github.com/sigstore/cosign/cmd/[email protected]
go install github.com/gohugoio/[email protected]+extended

# golicense no longer builds with go 1.18+, for now just install the last release binary
if [[ $(go env GOOS) == "darwin" ]]; then
curl -SLl https://github.com/mitchellh/golicense/releases/download/v0.2.0/golicense_0.2.0_macos_x86_64.tar.gz | tar -C /tmp -x
else
curl -SLl https://github.com/mitchellh/golicense/releases/download/v0.2.0/golicense_0.2.0_linux_x86_64.tar.gz | tar -C /tmp -x
fi
if [ -d "${HOME}/go/bin" ]; then
mv /tmp/golicense "${HOME}/go/bin"
fi

if ! echo "$PATH" | grep -q "${GOPATH:-undefined}/bin\|$HOME/go/bin"; then
echo "Go workspace's \"bin\" directory is not in PATH. Run 'export PATH=\"\$PATH:\${GOPATH:-\$HOME/go}/bin\"'."
fi
Expand Down

0 comments on commit 87435ea

Please sign in to comment.