nolint: drop allow-leading-space option and add "nolint:all" ()

This commit is contained in:
Ludovic Fernandez 2022-08-01 14:21:04 +02:00 committed by GitHub
parent 39fc81c19c
commit f8f8f9a6e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
22 changed files with 68 additions and 76 deletions
docs/src/docs/usage

View file

@ -95,11 +95,11 @@ run:
## Nolint Directive
To exclude issues from all linters use `//nolint`.
To exclude issues from all linters use `//nolint:all`.
For example, if it's used inline (not from the beginning of the line) it excludes issues only for this line.
```go
var bad_name int //nolint
var bad_name int //nolint:all
```
To exclude issues from specific linters only:
@ -111,7 +111,7 @@ var bad_name int //nolint:golint,unused
To exclude issues for the block of code use this directive on the beginning of a line:
```go
//nolint
//nolint:all
func allIssuesInThisFunctionAreExcluded() *string {
// ...
}