Lint-fix: Final golint, ignore capitalisation rules

This commit is contained in:
Calle Pettersson
2018-10-04 21:55:00 +02:00
committed by Calle Pettersson
parent 93904954f4
commit 0121fd6471
4 changed files with 6 additions and 3 deletions

View File

@@ -22,6 +22,7 @@ type CPUCollector struct {
DPCsTotal *prometheus.Desc DPCsTotal *prometheus.Desc
} }
// NewCPUCollector constructs a new CPUCollector
func NewCPUCollector() (Collector, error) { func NewCPUCollector() (Collector, error) {
const subsystem = "cpu" const subsystem = "cpu"
return &CPUCollector{ return &CPUCollector{

View File

@@ -980,7 +980,7 @@ type Win32_PerfRawData_W3SVC_WebServiceCache struct {
URICacheMisses uint32 URICacheMisses uint32
} }
var ApplicationStates = map[uint32]string{ var applicationStates = map[uint32]string{
1: "Uninitialized", 1: "Uninitialized",
2: "Initialized", 2: "Initialized",
3: "Running", 3: "Running",
@@ -1261,7 +1261,7 @@ func (c *IISCollector) collect(ch chan<- prometheus.Metric) (*prometheus.Desc, e
} }
// Guages // Guages
for key, label := range ApplicationStates { for key, label := range applicationStates {
isCurrentState := 0.0 isCurrentState := 0.0
if key == app.CurrentApplicationPoolState { if key == app.CurrentApplicationPoolState {
isCurrentState = 1.0 isCurrentState = 1.0

View File

@@ -38,6 +38,7 @@ type VmwareCollector struct {
HostProcessorSpeedMHz *prometheus.Desc HostProcessorSpeedMHz *prometheus.Desc
} }
// NewVmwareCollector constructs a new VmwareCollector
func NewVmwareCollector() (Collector, error) { func NewVmwareCollector() (Collector, error) {
const subsystem = "vmware" const subsystem = "vmware"
return &VmwareCollector{ return &VmwareCollector{

View File

@@ -6,6 +6,7 @@
], ],
"Exclude": [ "Exclude": [
"don't use underscores in Go names", "don't use underscores in Go names",
"exported type .+ should have comment or be unexported" "exported type .+ should have comment or be unexported",
"should be"
] ]
} }