Preparing report...

Report for github.com/dh1tw/remoteSwitch

A+    Excellent!    Found 13 issues across 29 files

Tweet

gofmt89%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo89%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.


golint58%

Golint is a linter for Go source code.

    • remoteSwitch/hub/hub.go
    • Line 191: warning: exported type Event should have comment or be unexported (golint)
    • Line 197: warning: exported type SwitchEvent should have comment or be unexported (golint)
    • Line 200: warning: exported const AddSwitch should have comment (or a comment on this block) or be unexported (golint)
    • remoteSwitch/switch/stackmatch_gpio/stackmatch.go
    • Line 1: warning: don't use MixedCaps in package name; StackmatchGPIO should be stackmatchgpio (golint)
    • Line 75: warning: exported method SmGPIO.Init should have comment or be unexported (golint)
    • Line 186: warning: exported method SmGPIO.Name should have comment or be unexported (golint)
    • Line 192: warning: exported method SmGPIO.SetPort should have comment or be unexported (golint)
    • Line 272: warning: exported method SmGPIO.GetPort should have comment or be unexported (golint)
    • Line 306: warning: exported method SmGPIO.Serialize should have comment or be unexported (golint)
    • Line 329: warning: exported method SmGPIO.Close should have comment or be unexported (golint)
    • remoteSwitch/switch/dummy_switch/dummy.go
    • Line 1: warning: don't use MixedCaps in package name; DummySwitch should be dummyswitch (golint)
    • Line 11: warning: exported type DummySwitch should have comment or be unexported (golint)
    • Line 36: warning: exported function NewDummySwitch should have comment or be unexported (golint)
    • Line 51: warning: exported method DummySwitch.Init should have comment or be unexported (golint)
    • remoteSwitch/switch/sbSwitchProxy/options.go
    • Line 1: warning: don't use MixedCaps in package name; sbSwitchProxy should be sbswitchproxy (golint)
    • Line 8: warning: exported function Client should have comment or be unexported (golint)
    • Line 23: warning: exported function Name should have comment or be unexported (golint)
    • Line 29: warning: exported function ServiceName should have comment or be unexported (golint)
    • remoteSwitch/switch/sbSwitchProxy/proxy.go
    • Line 1: warning: don't use MixedCaps in package name; sbSwitchProxy should be sbswitchproxy (golint)
    • Line 16: warning: exported type SbSwitchProxy should have comment or be unexported (golint)
    • Line 28: warning: exported function New should have comment or be unexported (golint)
    • Line 140: warning: exported method SbSwitchProxy.Name should have comment or be unexported (golint)
    • Line 146: warning: exported method SbSwitchProxy.GetPort should have comment or be unexported (golint)
    • Line 158: warning: exported method SbSwitchProxy.SetPort should have comment or be unexported (golint)
    • Line 182: warning: exported method SbSwitchProxy.Serialize should have comment or be unexported (golint)
    • Line 192: warning: exported method SbSwitchProxy.Close should have comment or be unexported (golint)
    • remoteSwitch/switch/ea4tx_remotebox/remotebox.go
    • Line 130: warning: exported type Remotebox should have comment or be unexported (golint)
    • Line 155: warning: exported function New should have comment or be unexported (golint)
    • Line 176: warning: exported method Remotebox.Init should have comment or be unexported (golint)
    • Line 237: warning: exported method Remotebox.Close should have comment or be unexported (golint)
    • remoteSwitch/switch/switch.go
    • Line 1: warning: don't use MixedCaps in package name; Switch should be switch (golint)
    • Line 3: warning: exported type Switcher should have comment or be unexported (golint)
    • Line 11: warning: exported type Device should have comment or be unexported (golint)
    • Line 17: warning: exported type Port should have comment or be unexported (golint)
    • Line 23: warning: exported type Terminal should have comment or be unexported (golint)
    • remoteSwitch/switch/stackmatch_gpio/options.go
    • Line 1: warning: don't use MixedCaps in package name; StackmatchGPIO should be stackmatchgpio (golint)
    • Line 5: warning: comment on exported function Config should be of the form "Config ..." (golint)
    • Line 12: warning: exported type SmConfig should have comment or be unexported (golint)
    • Line 18: warning: exported type CombinationConfig should have comment or be unexported (golint)
    • Line 24: warning: exported type TerminalConfig should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign96%

IneffAssign detects ineffectual assignments in Go code.


misspell96%

Misspell Finds commonly misspelled English words