Preparing report...

Report for github.com/jswidler/lockgit

A+    Excellent!    Found 13 issues across 35 files

Tweet

gofmt100%

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

No problems detected. Good job!


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!


gocyclo100%

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.

No problems detected. Good job!


golint62%

Golint is a linter for Go source code.

    • lockgit/pkg/cmd/zzzroot.go
    • Line 101: warning: comment on exported function InitConfig should be of the form "InitConfig ..." (golint)
    • Line 165: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • lockgit/pkg/app/entry.go
    • Line 37: warning: exported type Options should have comment or be unexported (golint)
    • Line 43: warning: comment on exported function InitVault should be of the form "InitVault ..." (golint)
    • Line 70: warning: exported function SetKey should have comment or be unexported (golint)
    • Line 88: warning: exported function UnsetKey should have comment or be unexported (golint)
    • Line 107: warning: exported function GetKey should have comment or be unexported (golint)
    • Line 112: warning: exported function Ls should have comment or be unexported (golint)
    • Line 121: warning: exported function LsGlobs should have comment or be unexported (golint)
    • Line 130: warning: exported function AddToVault should have comment or be unexported (golint)
    • Line 191: warning: exported function RemoveFromVault should have comment or be unexported (golint)
    • Line 234: warning: exported function Commit should have comment or be unexported (golint)
    • Line 302: warning: exported function OpenVault should have comment or be unexported (golint)
    • Line 311: warning: exported function CloseVault should have comment or be unexported (golint)
    • lockgit/pkg/app/lockgit.go
    • Line 47: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 158: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • lockgit/pkg/content/datafile.go
    • Line 41: warning: exported type Datafile should have comment or be unexported (golint)
    • Line 53: warning: exported function NewDatafile should have comment or be unexported (golint)
    • Line 78: warning: exported method Datafile.Path should have comment or be unexported (golint)
    • Line 82: warning: exported method Datafile.Perm should have comment or be unexported (golint)
    • Line 86: warning: exported method Datafile.Serialize should have comment or be unexported (golint)
    • Line 99: warning: exported function MakeDatafilePath should have comment or be unexported (golint)
    • Line 103: warning: exported method Datafile.Id should have comment or be unexported (golint)
    • Line 111: warning: comment on exported method Datafile.MatchesCurrent should be of the form "MatchesCurrent ..." (golint)
    • Line 121: warning: exported method Datafile.Equal should have comment or be unexported (golint)
    • Line 125: warning: exported function ReadDatafile should have comment or be unexported (golint)
    • Line 139: warning: exported method Datafile.DecodeData should have comment or be unexported (golint)
    • lockgit/pkg/content/errors.go
    • Line 27: warning: exported type KeyLoadError should have comment or be unexported (golint)
    • Line 35: warning: exported function IsKeyLoadError should have comment or be unexported (golint)
    • Line 45: warning: exported type ManifestLoadError should have comment or be unexported (golint)
    • Line 54: warning: exported function IsManifestLoadError should have comment or be unexported (golint)
    • lockgit/pkg/content/filemeta.go
    • Line 28: warning: comment on exported type Filemeta should be of the form "Filemeta ..." (with optional leading article) (golint)
    • Line 35: warning: exported function NewFilemeta should have comment or be unexported (golint)
    • Line 43: warning: exported method Filemeta.IdString should have comment or be unexported (golint)
    • lockgit/pkg/log/log.go
    • Line 10: warning: comment on exported function LogError should be of the form "LogError ..." (golint)
    • Line 17: warning: comment on exported function Info should be of the form "Info ..." (golint)
    • Line 22: warning: exported function Infof should have comment or be unexported (golint)
    • Line 26: warning: comment on exported function Verbose should be of the form "Verbose ..." (golint)
    • Line 31: warning: exported function FatalExit should have comment or be unexported (golint)
    • Line 38: warning: exported function FatalPanic should have comment or be unexported (golint)
    • lockgit/pkg/util/util.go
    • Line 29: warning: exported type FileResult should have comment or be unexported (golint)
    • Line 32: warning: exported const File should have comment (or a comment on this block) or be unexported (golint)
    • Line 37: warning: exported function GetFiles should have comment or be unexported (golint)
    • Line 45: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 68: warning: comment on exported function Exists should be of the form "Exists ..." (golint)
    • Line 80: warning: comment on exported function ExistsDir should be of the form "ExistsDir ..." (golint)
    • Line 92: warning: exported function Filter should have comment or be unexported (golint)
    • lockgit/pkg/content/context.go
    • Line 36: warning: exported type Context should have comment or be unexported (golint)
    • Line 47: warning: comment on exported function FromPath should be of the form "FromPath ..." (golint)
    • Line 141: warning: exported method Context.ImportManifest should have comment or be unexported (golint)
    • Line 145: warning: exported method Context.RelPath should have comment or be unexported (golint)
    • Line 153: warning: exported method Context.ProjRelPath should have comment or be unexported (golint)
    • lockgit/pkg/content/lgconfig.go
    • Line 33: warning: exported type LgConfig should have comment or be unexported (golint)
    • Line 39: warning: exported function NewLgConfig should have comment or be unexported (golint)
    • Line 49: warning: exported method LgConfig.AddPattern should have comment or be unexported (golint)
    • Line 62: warning: exported method LgConfig.RemovePattern should have comment or be unexported (golint)
    • Line 71: warning: exported method LgConfig.FindPattern should have comment or be unexported (golint)
    • Line 79: warning: receiver name config should be consistent with previous receiver name c for LgConfig (golint)
    • Line 86: warning: exported function ReadConfig should have comment or be unexported (golint)
    • lockgit/pkg/content/manifest.go
    • Line 36: warning: exported type Manifest should have comment or be unexported (golint)
    • Line 41: warning: exported method Manifest.Export should have comment or be unexported (golint)
    • Line 46: warning: exported function ImportManifest should have comment or be unexported (golint)
    • Line 79: warning: exported method Manifest.Find should have comment or be unexported (golint)
    • Line 87: warning: exported method Manifest.Add 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!