Add golangci-lint #2
Annotations
10 errors and 8 warnings
lint:
gobrew.go#L88
string `None` has 16 occurrences, make it a constant (goconst)
|
lint:
gobrew.go#L341
string `gobrew` has 5 occurrences, make it a constant (goconst)
|
lint:
cmd/gobrew/main.go#L70
assignOp: replace `versionArg = versionArg + ".0"` with `versionArg += ".0"` (gocritic)
|
|
lint:
helpers.go#L277
badCall: suspicious Join on 1 argument (gocritic)
|
lint:
helpers.go#L292
badCall: suspicious Join on 1 argument (gocritic)
|
lint:
helpers.go#L348
badCall: suspicious Join on 1 argument (gocritic)
|
lint:
helpers.go#L311
exitAfterDefer: os.Exit will exit, and `defer func(modFile *os.File){...}(...)` will not run (gocritic)
|
lint:
helpers.go#L441
exitAfterDefer: os.Exit will exit, and `defer func(body io.ReadCloser){...}(...)` will not run (gocritic)
|
lint:
helpers.go#L75
regexpMust: for const patterns like "[0-9]+.0.0", use regexp.MustCompile (gocritic)
|
lint:
gobrew_test.go#L16
var-naming: var versionUrl should be versionURL (revive)
|
lint:
gobrew.go#L23
var-naming: const DownloadUrl should be DownloadURL (revive)
|
lint:
gobrew.go#L24
var-naming: const TagsApi should be TagsAPI (revive)
|
lint:
gobrew.go#L25
var-naming: const VersionsUrl should be VersionsURL (revive)
|
lint:
gobrew.go#L58
var-naming: struct field RegistryPathUrl should be RegistryPathURL (revive)
|
lint:
gobrew.go#L59
var-naming: struct field GobrewDownloadUrl should be GobrewDownloadURL (revive)
|
lint:
gobrew.go#L61
var-naming: struct field GobrewVersionsUrl should be GobrewVersionsURL (revive)
|
lint:
gobrew.go#L342
var-naming: var downloadUrl should be downloadURL (revive)
|