Skip to content

Commit 094668e

Browse files
authored
docs: improve 'install from sources' section (#5050)
1 parent 5956285 commit 094668e

File tree

1 file changed

+11
-16
lines changed

1 file changed

+11
-16
lines changed

docs/src/docs/welcome/install.mdx

+11-16
Original file line numberDiff line numberDiff line change
@@ -132,31 +132,26 @@ Colored output:
132132
docker run -t --rm -v $(pwd):/app -w /app golangci/golangci-lint:{.LatestVersion} golangci-lint run -v
133133
```
134134

135-
### Install from Source
135+
### Install from Sources
136136

137-
Note: such `go install`/`go get` installation aren't guaranteed to work. We recommend using binary installation.
137+
Such `go install`/`go get` or "tools pattern" installations aren't guaranteed to work.
138138

139-
<details>
140-
<summary>Why?</summary>
139+
We recommend using binary installation.
141140

142-
`go install`/`go get` installation isn't recommended because of the following points:
141+
Those installations aren't recommended because of the following points:
143142

144-
1. Some users use `-u` flag for `go get`, which upgrades our dependencies. Resulting configuration wasn't tested and isn't guaranteed to work.
145-
2. [`go.mod`](https://github.com/golangci/golangci-lint/blob/master/go.mod) replacement directive doesn't apply. It means a user will be using patched version of `golangci-lint` if we use such replacements.
146-
3. We've encountered a lot of issues with Go modules hashes.
147-
4. It allows installation from `master` branch which can't be considered stable.
148-
5. It's slower than binary installation.
149-
150-
</details>
151-
152-
<div style="margin-top: 2em;">
143+
1. Those installations are compiling golangci-lint locally, the Go version used to build will depend on your local Go version.
144+
2. Some users use `-u` flag for `go get`, which upgrades our dependencies. Resulting binary was not tested and is not guaranteed to work.
145+
3. When using "tools pattern", the dependencies of a tool can modify the dependencies of another. Resulting binary was not tested and is not guaranteed to work.
146+
4. We've encountered issues with Go modules hashes due to unexpected recreation of dependency tags.
147+
5. `go.mod` replacement directives don't apply transitively. It means a user will be using patched version of `golangci-lint` if we use such replacements.
148+
6. It allows installation from main branch which can't be considered stable.
149+
7. It's slower than binary installation.
153150

154151
```sh
155152
go install github.com/golangci/golangci-lint/cmd/golangci-lint@{.LatestVersion}
156153
```
157154

158-
</div>
159-
160155
## Next
161156

162157
[Quick Start: how to use `golangci-lint`](/welcome/quick-start/).

0 commit comments

Comments
 (0)