From 6305526cf87d146cb5347c9fc95b1662402f8dc4 Mon Sep 17 00:00:00 2001 From: Daniel Mikusa Date: Thu, 11 Aug 2022 03:51:16 -0400 Subject: [PATCH] Use curl to install richgo (#167) This PR changes the workflow to use 'curl' to fetch and install richgo instead of 'go get'. We could switch to 'go install', but 'curl' is faster than fetching & building. This is what the pipeline-builder project has been doing to install richgo for quite a while now. Signed-off-by: Daniel Mikusa Signed-off-by: Daniel Mikusa --- .github/pipeline-descriptor.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/pipeline-descriptor.yml b/.github/pipeline-descriptor.yml index ac5e76e..253cec0 100644 --- a/.github/pipeline-descriptor.yml +++ b/.github/pipeline-descriptor.yml @@ -14,7 +14,19 @@ test: set -euo pipefail - GO111MODULE=on go get -u -ldflags="-s -w" github.com/kyoh86/richgo + echo "Installing richgo ${RICHGO_VERSION}" + + mkdir -p "${HOME}"/bin + echo "${HOME}/bin" >> "${GITHUB_PATH}" + + curl \ + --location \ + --show-error \ + --silent \ + "https://github.com/kyoh86/richgo/releases/download/v${RICHGO_VERSION}/richgo_${RICHGO_VERSION}_linux_amd64.tar.gz" \ + | tar -C "${HOME}"/bin -xz richgo + env: + RICHGO_VERSION: 0.3.10 - name: Run Tests run: | #!/usr/bin/env bash