我有一个Makefile正在circleci上运行一些目标这是的目标Makefile
install_lint:
curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s v1.21.0
当我在第二个目标上运行时golangci-lint --version出现错误golangci-lint: Command not found
我也尝试过这个
curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s -- -b $(go env GOPATH)/bin v1.21.0
因为我正在运行 docker1.13.2
version: 2
jobs:
build:
docker:
- image: circleci/golang:1.13.3
知道我在这里缺少什么吗?如何使二进制可用?
我也尝试过类似的东西
install_lint:
curl -sLO https://github.com/golangci/golangci-lint/releases/download/v${GOLANGCI_VERSION}/golangci-lint-${GOLANGCI_VERSION}-linux-amd64.tar.gz
tar -xzvf golangci-lint-${GOLANGCI_VERSION}-linux-amd64.tar.gz
cp golangci-lint-${GOLANGCI_VERSION}-linux-amd64/golangci-lint /usr/local/bin/golangci-lint && chmod +x /usr/local/bin/golangci-lint
我得到了错误
cp: cannot create regular file '/usr/local/bin/golangci-lint': Permission denied
一只萌萌小番薯
相关分类