You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
698 B
Bash

#!/bin/bash
# Install protoc
if [[ ! -x /go/bin/protoc-gen-micro ]]; then
cd /tmp
go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.28
go install github.com/go-micro/generator/cmd/protoc-gen-micro@v1.0.0
fi
# Install task
if [[ ! -x /go/bin/task ]]; then
sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /go/bin
fi
# Install trunk
if [[ ! -x /go/bin/trunk ]]; then
pushd /go/bin
curl -LO https://trunk.io/releases/trunk
chmod +x trunk
popd
fi
# Install golangci-lint
if [[ ! -x /go/bin/golangci-lint ]]; then
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b /go/bin
fi
exec "$@"