diff --git a/src/lint.md b/src/lint.md index 03d8301..41fd519 100644 --- a/src/lint.md +++ b/src/lint.md @@ -9,16 +9,18 @@ quality without being unnecessarily prescriptive: - [errcheck] to ensure that errors are handled - [goimports] to format code and manage imports -- [golint] to point out common style mistakes +- [revive] to point out common style mistakes - [govet] to analyze code for common mistakes - [staticcheck] to do various static analysis checks [errcheck]: https://github.com/kisielk/errcheck [goimports]: https://pkg.go.dev/golang.org/x/tools/cmd/goimports - [golint]: https://github.com/golang/lint + [revive]: https://github.com/mgechev/revive [govet]: https://pkg.go.dev/cmd/vet [staticcheck]: https://staticcheck.dev + > **Note**: [revive] is the modern, faster successor to the now-deprecated [golint]. + ## Lint Runners We recommend [golangci-lint] as the go-to lint runner for Go code, largely due @@ -33,3 +35,5 @@ that make sense for their projects. [golangci-lint]: https://github.com/golangci/golangci-lint [.golangci.yml]: https://github.com/uber-go/guide/blob/master/.golangci.yml [various linters]: https://golangci-lint.run/usage/linters/ + [golint]: https://github.com/golang/lint + diff --git a/style.md b/style.md index 6ffaff4..5ae44a2 100644 --- a/style.md +++ b/style.md @@ -4089,10 +4089,12 @@ quality without being unnecessarily prescriptive: - [errcheck](https://github.com/kisielk/errcheck) to ensure that errors are handled - [goimports](https://pkg.go.dev/golang.org/x/tools/cmd/goimports) to format code and manage imports -- [golint](https://github.com/golang/lint) to point out common style mistakes +- [revive](https://github.com/mgechev/revive) to point out common style mistakes - [govet](https://pkg.go.dev/cmd/vet) to analyze code for common mistakes - [staticcheck](https://staticcheck.dev) to do various static analysis checks + > **Note**: [revive](https://github.com/mgechev/revive) is the modern, faster successor to the now-deprecated [golint](https://github.com/golang/lint). + ### Lint Runners We recommend [golangci-lint](https://github.com/golangci/golangci-lint) as the go-to lint runner for Go code, largely due