Preparing report...

Report for github.com/evercyan/leetcli

A+    Excellent!    Found 42 issues across 286 files

Tweet

gofmt99%

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!


gocyclo98%

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.

    • leetcli/main.go
    • Line 588: warning: cyclomatic complexity 42 of function main() is high (> 15) (gocyclo)
    • Line 419: warning: cyclomatic complexity 16 of function (*leetCodeFile).GenerateQuestion() is high (> 15) (gocyclo)

golint86%

Golint is a linter for Go source code.

    • leetcli/src/0146-lru-cache/solution.go
    • Line 7: warning: exported type LRUCache should have comment or be unexported (golint)
    • Line 13: warning: exported function Constructor should have comment or be unexported (golint)
    • Line 22: warning: exported method LRUCache.Get should have comment or be unexported (golint)
    • Line 31: warning: exported method LRUCache.Put should have comment or be unexported (golint)
    • Line 50: warning: exported method LRUCache.MoveToFront should have comment or be unexported (golint)
    • leetcli/src/0981-time-based-key-value-store/solution.go
    • Line 9: warning: exported type TimeMap should have comment or be unexported (golint)
    • Line 14: warning: exported function Constructor should have comment or be unexported (golint)
    • Line 21: warning: exported method TimeMap.Set should have comment or be unexported (golint)
    • Line 31: warning: exported method TimeMap.Get should have comment or be unexported (golint)
    • leetcli/src/0155-min-stack/solution.go
    • Line 9: warning: exported type MinStack should have comment or be unexported (golint)
    • Line 14: warning: exported function Constructor should have comment or be unexported (golint)
    • Line 20: warning: exported method MinStack.Push should have comment or be unexported (golint)
    • Line 34: warning: exported method MinStack.Pop should have comment or be unexported (golint)
    • Line 41: warning: exported method MinStack.Top should have comment or be unexported (golint)
    • Line 48: warning: exported method MinStack.GetMin should have comment or be unexported (golint)
    • leetcli/src/util.go
    • Line 12: warning: exported type ListNode should have comment or be unexported (golint)
    • Line 17: warning: exported type TreeNode should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!