-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: more stringent golangci-lint rules
Applies more stringent `golangci-lint` rules to the repository, borrowed from https://github.com/nix-community/go-nix. Also fixes a bug where we were not returning errors when calling `walk.Reader.Read()` in `cmd/format` Signed-off-by: Brian McGee <[email protected]>
- Loading branch information
1 parent
7b6fc1b
commit f4f9d77
Showing
25 changed files
with
286 additions
and
190 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
linters: | ||
enable: | ||
- errname | ||
- exhaustive | ||
- gci | ||
- gochecknoglobals | ||
- gochecknoinits | ||
- goconst | ||
- godot | ||
- gofumpt | ||
- goheader | ||
- goimports | ||
- gosec | ||
- importas | ||
- ireturn | ||
- lll | ||
- makezero | ||
- misspell | ||
- nakedret | ||
- nestif | ||
- nilerr | ||
- nilnil | ||
- nlreturn | ||
- noctx | ||
- nolintlint | ||
- prealloc | ||
- predeclared | ||
- revive | ||
- rowserrcheck | ||
- stylecheck | ||
- tagliatelle | ||
- tenv | ||
- testpackage | ||
- unconvert | ||
- unparam | ||
- wastedassign | ||
- whitespace | ||
- wsl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package build | ||
|
||
var ( | ||
Name = "treefmt" | ||
//nolint:gochecknoglobals | ||
Name = "treefmt" | ||
//nolint:gochecknoglobals | ||
Version = "v0.0.1+dev" | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.