@@ -54,8 +54,8 @@ The recommended way to install golangci-lint (replace `vX.Y.Z` with the latest
54
54
version from the [ releases page] ( https://github.com/golangci/golangci-lint/releases ) ):
55
55
56
56
``` bash
57
- # binary will be $GOPATH/bin/golangci-lint
58
- curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $GOPATH /bin vX.Y.Z
57
+ # binary will be $(go env GOPATH) /bin/golangci-lint
58
+ curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $( go env GOPATH) /bin vX.Y.Z
59
59
60
60
# or install it into ./bin/
61
61
curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s vX.Y.Z
@@ -69,8 +69,8 @@ golangci-lint --version
69
69
As a fallback you can also use ` raw.githubusercontent.com `
70
70
71
71
``` bash
72
- # binary will be $GOPATH/bin/golangci-lint
73
- curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s -- -b $GOPATH /bin vX.Y.Z
72
+ # binary will be $(go env GOPATH) /bin/golangci-lint
73
+ curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s -- -b $( go env GOPATH) /bin vX.Y.Z
74
74
75
75
# or install it into ./bin/
76
76
curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s vX.Y.Z
@@ -91,7 +91,7 @@ It's a not recommended for your CI pipeline. Only install like this for your loc
91
91
92
92
``` bash
93
93
go get -u github.com/golangci/golangci-lint
94
- cd $GOPATH /src/github.com/golangci/golangci-lint/cmd/golangci-lint
94
+ cd $( go env GOPATH) /src/github.com/golangci/golangci-lint/cmd/golangci-lint
95
95
go install -ldflags " -X 'main.version=$( git describe --tags) ' -X 'main.commit=$( git rev-parse --short HEAD) ' -X 'main.date=$( date) '"
96
96
```
97
97
0 commit comments