Enable stylecheck linter
Add stylecheck linter to golangci-lint. * Fix style issues. Signed-off-by: Ben Kochie <superq@gmail.com>
This commit is contained in:
parent
6d18ce7bca
commit
e5b09ec144
|
@ -2,6 +2,7 @@ linters:
|
||||||
enable:
|
enable:
|
||||||
- misspell
|
- misspell
|
||||||
- revive
|
- revive
|
||||||
|
- stylecheck
|
||||||
disable:
|
disable:
|
||||||
# Disable soon to deprecated[1] linters that lead to false
|
# Disable soon to deprecated[1] linters that lead to false
|
||||||
# positives when build tags disable certain files[2]
|
# positives when build tags disable certain files[2]
|
||||||
|
|
|
@ -84,7 +84,7 @@ func NewCPUCollector(logger log.Logger) (Collector, error) {
|
||||||
isolcpus, err := sysfs.IsolatedCPUs()
|
isolcpus, err := sysfs.IsolatedCPUs()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
if !os.IsNotExist(err) {
|
if !os.IsNotExist(err) {
|
||||||
return nil, fmt.Errorf("Unable to get isolated cpus: %w", err)
|
return nil, fmt.Errorf("unable to get isolated cpus: %w", err)
|
||||||
}
|
}
|
||||||
level.Debug(logger).Log("msg", "Could not open isolated file", "error", err)
|
level.Debug(logger).Log("msg", "Could not open isolated file", "error", err)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue