Skip to content

Commit

Permalink
chore: Maintain local copy of goreleaser install script
Browse files Browse the repository at this point in the history
Since goreleaser/godownloader has been deprecated
goreleaser/godownloader#207 we maintain our
own local copy of the `install.sh` script similar to
https://github.com/golangci/golangci-lint/blob/master/install.sh
until we find a proper replacement.

Signed-off-by: Justin Toh <[email protected]>
  • Loading branch information
tohjustin committed Oct 24, 2021
1 parent 6b257b7 commit 9dabf8b
Show file tree
Hide file tree
Showing 2 changed files with 406 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/fetch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ fetch() {
local tool_fetch_cmd=""
case "$tool" in
"golangci-lint")
ver_cmd="${ROOT}/bin/golangci-lint --version 2>/dev/null | cut -d\" \" -f4"
fetch_cmd="curl -sSfL \"https://raw.githubusercontent.com/golangci/golangci-lint/v${ver}/install.sh\" | sh -s -- -b \"${ROOT}/bin\" \"v${ver}\""
ver_cmd="${ROOT}/bin/golangci-lint --version 2>/dev/null | cut -d' ' -f4"
fetch_cmd="curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/v${ver}/install.sh | sh -s -- -b \"${ROOT}/bin\" \"v${ver}\""
;;
"goreleaser")
ver_cmd="${ROOT}/bin/goreleaser --version 2>/dev/null | grep 'goreleaser version' | cut -d' ' -f3"
fetch_cmd="curl -sSfL https://install.goreleaser.com/github.com/goreleaser/goreleaser.sh | sh -s -- -b \"${ROOT}/bin\" -d \"v${ver}\""
fetch_cmd="cat ${ROOT}/scripts/goreleaser_install.sh | sh -s -- -b \"${ROOT}/bin\" -d \"v${ver}\""
;;
*)
echo "unknown tool $tool"
Expand Down
Loading

0 comments on commit 9dabf8b

Please sign in to comment.