Preparing report...

Report for github.com/monochromegane/the_platinum_searcher

B    Not bad!    Found 33 issues across 34 files

Tweet

gofmt79%

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!


golint8%

Golint is a linter for Go source code.

    • the_platinum_searcher/decorator.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 10: warning: exported const ColorReset should have comment (or a comment on this block) or be unexported (golint)
    • Line 26: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • the_platinum_searcher/option.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 5: warning: comment on exported type Option should be of the form "Option ..." (with optional leading article) (golint)
    • Line 12: warning: comment on exported type OutputOption should be of the form "OutputOption ..." (with optional leading article) (golint)
    • Line 67: warning: exported method OutputOption.SetEnableColor should have comment or be unexported (golint)
    • Line 72: warning: exported method OutputOption.SetDisableColor should have comment or be unexported (golint)
    • Line 76: warning: exported method OutputOption.SetEnableLineNumber should have comment or be unexported (golint)
    • Line 81: warning: exported method OutputOption.SetDisableLineNumber should have comment or be unexported (golint)
    • Line 85: warning: exported method OutputOption.SetEnableGroup should have comment or be unexported (golint)
    • Line 90: warning: exported method OutputOption.SetDisableGroup should have comment or be unexported (golint)
    • Line 94: warning: exported method OutputOption.SetColorLineNumber should have comment or be unexported (golint)
    • Line 98: warning: exported method OutputOption.SetColorPath should have comment or be unexported (golint)
    • Line 102: warning: exported method OutputOption.SetColorMatch should have comment or be unexported (golint)
    • Line 106: warning: comment on exported type SearchOption should be of the form "SearchOption ..." (with optional leading article) (golint)
    • Line 127: warning: exported method SearchOption.SetFilesWithRegexp should have comment or be unexported (golint)
    • the_platinum_searcher/buffer_grep.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 73: warning: should omit 2nd value from range; this loop is equivalent to `for i := range ...` (golint)
    • Line 88: warning: exported var NewLineBytes should have comment or be unexported (golint)
    • the_platinum_searcher/platinum_searcher.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 19: warning: exported const ExitCodeOK should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported type PlatinumSearcher should have comment or be unexported (golint)
    • Line 29: warning: exported method PlatinumSearcher.Run should have comment or be unexported (golint)
    • Line 104: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • the_platinum_searcher/file_info.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 18: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • the_platinum_searcher/match_state.go
    • Line 1: warning: don't use an underscore in package name (golint)
    • Line 20: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 46: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 72: warning: if block ends with a return statement, so drop this else and outdent its block (golint)

gocyclo82%

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.


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!