Preparing report...

Report for github.com/plumming/dx

A+    Excellent!    Found 40 issues across 69 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!


golint42%

Golint is a linter for Go source code.

    • dx/pkg/cmd/common.go
    • Line 14: warning: exported type CommonOptions should have comment or be unexported (golint)
    • Line 23: warning: exported method CommonOptions.SetPrompter should have comment or be unexported (golint)
    • Line 27: warning: exported method CommonOptions.Prompter should have comment or be unexported (golint)
    • Line 34: warning: exported method CommonOptions.SetNonGithubClient should have comment or be unexported (golint)
    • Line 38: warning: exported method CommonOptions.NonGithubClient should have comment or be unexported (golint)
    • Line 45: warning: exported method CommonOptions.SetGithubClient should have comment or be unexported (golint)
    • Line 49: warning: exported method CommonOptions.GithubClient should have comment or be unexported (golint)
    • Line 60: warning: exported method CommonOptions.SetKuber should have comment or be unexported (golint)
    • Line 64: warning: exported method CommonOptions.Kuber should have comment or be unexported (golint)
    • Line 71: warning: exported method CommonOptions.SetConfig should have comment or be unexported (golint)
    • Line 75: warning: exported method CommonOptions.Config should have comment or be unexported (golint)
    • Line 86: warning: exported method CommonOptions.FakeKubeClient should have comment or be unexported (golint)
    • Line 93: warning: exported method CommonOptions.KubeClient should have comment or be unexported (golint)
    • dx/pkg/httpmock/legacy.go
    • Line 14: warning: exported method Registry.StubResponse should have comment or be unexported (golint)
    • Line 20: warning: exported method Registry.StubWithFixture should have comment or be unexported (golint)
    • Line 36: warning: exported method Registry.StubRepoResponse should have comment or be unexported (golint)
    • Line 40: warning: exported method Registry.StubRepoResponseWithPermission should have comment or be unexported (golint)
    • Line 44: warning: exported method Registry.StubRepoResponseWithDefaultBranch should have comment or be unexported (golint)
    • Line 48: warning: exported method Registry.StubForkedRepoResponse should have comment or be unexported (golint)
    • Line 52: warning: exported function RepoNetworkStubResponse should have comment or be unexported (golint)
    • Line 66: warning: exported function RepoNetworkStubForkResponse should have comment or be unexported (golint)
    • dx/pkg/domain/git.go
    • Line 15: warning: exported var Runner should have comment or be unexported (golint)
    • Line 18: warning: exported function GetRemote should have comment or be unexported (golint)
    • Line 31: warning: exported function CurrentBranchName should have comment or be unexported (golint)
    • Line 44: warning: exported function Stash should have comment or be unexported (golint)
    • Line 59: warning: exported function StashPop should have comment or be unexported (golint)
    • Line 72: warning: exported function Add should have comment or be unexported (golint)
    • Line 85: warning: exported function Commit should have comment or be unexported (golint)
    • Line 98: warning: exported function Status should have comment or be unexported (golint)
    • Line 111: warning: exported function LocalChanges should have comment or be unexported (golint)
    • Line 135: warning: exported function ConfigCommitterInformation should have comment or be unexported (golint)
    • Line 158: warning: exported function ExtractURLFromRemote should have comment or be unexported (golint)
    • Line 184: warning: exported function ExtractOrgAndRepoURL should have comment or be unexported (golint)
    • dx/pkg/api/client.go
    • Line 232: warning: exported method Client.Do should have comment or be unexported (golint)
    • Line 255: warning: exported function BasicClient should have comment or be unexported (golint)
    • Line 276: warning: exported function Mask should have comment or be unexported (golint)
    • Line 287: warning: exported function ReplaceAllGroupFunc should have comment or be unexported (golint)
    • dx/pkg/httpmock/stub.go
    • Line 10: warning: exported type Matcher should have comment or be unexported (golint)
    • Line 11: warning: exported type Responder should have comment or be unexported (golint)
    • Line 13: warning: exported type Stub should have comment or be unexported (golint)
    • Line 19: warning: exported function MatchAny should have comment or be unexported (golint)
    • Line 23: warning: exported function StringResponse should have comment or be unexported (golint)
    • dx/pkg/api/fake_http.go
    • Line 46: warning: exported method FakeHTTP.StubWithFixture should have comment or be unexported (golint)
    • Line 53: warning: exported method FakeHTTP.StubRepoResponse should have comment or be unexported (golint)
    • Line 57: warning: exported method FakeHTTP.StubRepoResponseWithPermission should have comment or be unexported (golint)
    • Line 79: warning: exported method FakeHTTP.StubForkedRepoResponse should have comment or be unexported (golint)
    • dx/pkg/config/file.go
    • Line 29: warning: exported method Config.ReposToQuery should have comment or be unexported (golint)
    • Line 37: warning: exported function LoadFromFile should have comment or be unexported (golint)
    • Line 62: warning: exported method Config.SetDefaults should have comment or be unexported (golint)
    • Line 84: warning: exported function LoadFromDefaultLocation should have comment or be unexported (golint)
    • Line 88: warning: exported method Config.SaveToDefaultLocation should have comment or be unexported (golint)
    • Line 92: warning: exported method Config.SaveToFile should have comment or be unexported (golint)
    • dx/pkg/cmd/deletecmd/delete_repos.go
    • Line 12: warning: exported type DeleteReposCmd should have comment or be unexported (golint)
    • Line 20: warning: exported function NewDeleteReposCmd should have comment or be unexported (golint)
    • Line 49: warning: exported method DeleteReposCmd.Run should have comment or be unexported (golint)
    • dx/pkg/update/update.go
    • Line 22: warning: exported type StateEntry should have comment or be unexported (golint)
    • Line 43: warning: exported function GetLatestReleaseInfo should have comment or be unexported (golint)
    • dx/pkg/util/color.go
    • Line 9: warning: exported var InfoColor should have comment or be unexported (golint)
    • Line 43: warning: exported function Strip should have comment or be unexported (golint)
    • dx/pkg/util/format.go
    • Line 11: warning: exported function SafeTime should have comment or be unexported (golint)
    • Line 19: warning: exported function TrimTemplate should have comment or be unexported (golint)
    • dx/pkg/cmd/contextcmd/context.go
    • Line 10: warning: exported type ContextCmd should have comment or be unexported (golint)
    • Line 15: warning: exported function NewContextCmd should have comment or be unexported (golint)
    • Line 36: warning: exported method ContextCmd.Run should have comment or be unexported (golint)
    • dx/pkg/cmd/getcmd/get_prs.go
    • Line 19: warning: exported type GetPrsCmd should have comment or be unexported (golint)
    • Line 31: warning: exported function NewGetPrsCmd should have comment or be unexported (golint)
    • Line 85: warning: exported method GetPrsCmd.Run should have comment or be unexported (golint)
    • dx/pkg/domain/gh.go
    • Line 9: warning: exported function GetDefaultBranch should have comment or be unexported (golint)
    • Line 19: warning: exported function GetCurrentUser should have comment or be unexported (golint)
    • Line 29: warning: exported function GetOrgsForUser should have comment or be unexported (golint)
    • dx/pkg/api/config_type.go
    • Line 16: warning: comment on exported type NotFoundError should be of the form "NotFoundError ..." (with optional leading article) (golint)
    • Line 21: warning: comment on exported type HostConfig should be of the form "HostConfig ..." (with optional leading article) (golint)
    • dx/pkg/cmd/getcmd/get_repos.go
    • Line 13: warning: exported type GetReposCmd should have comment or be unexported (golint)
    • Line 21: warning: exported function NewGetReposCmd should have comment or be unexported (golint)
    • Line 50: warning: exported method GetReposCmd.Run should have comment or be unexported (golint)
    • dx/pkg/domain/get_prs.go
    • Line 28: warning: comment on exported type Data should be of the form "Data ..." (with optional leading article) (golint)
    • Line 33: warning: comment on exported type Search should be of the form "Search ..." (with optional leading article) (golint)
    • Line 38: warning: comment on exported function NewGetPrs should be of the form "NewGetPrs ..." (golint)
    • dx/pkg/cmd/common_cmd.go
    • Line 13: warning: exported type CommonCmd should have comment or be unexported (golint)
    • Line 17: warning: exported method CommonCmd.AddOptions should have comment or be unexported (golint)
    • Line 21: warning: exported method CommonCmd.Filter should have comment or be unexported (golint)
    • dx/pkg/cmd/rebasecmd/rebase.go
    • Line 10: warning: exported type RebaseCmd should have comment or be unexported (golint)
    • Line 15: warning: exported function NewRebaseCmd should have comment or be unexported (golint)
    • Line 37: warning: exported method RebaseCmd.Run should have comment or be unexported (golint)
    • dx/pkg/cmd/editcmd/edit_config.go
    • Line 13: warning: exported type EditConfigCmd should have comment or be unexported (golint)
    • Line 22: warning: exported function NewEditConfigCmd should have comment or be unexported (golint)
    • Line 44: warning: exported method EditConfigCmd.Run should have comment or be unexported (golint)
    • dx/pkg/domain/repos.go
    • Line 12: warning: exported type Repo should have comment or be unexported (golint)
    • Line 16: warning: exported method Repo.ListRepositoriesForOrg should have comment or be unexported (golint)
    • Line 31: warning: exported method Repo.ListRepositoriesForUser should have comment or be unexported (golint)
    • Line 46: warning: exported method Repo.SelectRepositories should have comment or be unexported (golint)
    • Line 62: warning: exported method Repo.DeleteRepositoriesFromOrg should have comment or be unexported (golint)
    • Line 84: warning: exported method Repo.DeleteRepositoriesFromUser should have comment or be unexported (golint)
    • Line 114: warning: exported type RepoInfo should have comment or be unexported (golint)
    • dx/pkg/pr/pr.go
    • Line 12: warning: exported type PullRequest should have comment or be unexported (golint)
    • Line 35: warning: exported method PullRequest.Display should have comment or be unexported (golint)
    • Line 45: warning: exported method PullRequest.LabelsString should have comment or be unexported (golint)
    • Line 66: warning: exported method PullRequest.ContextsString should have comment or be unexported (golint)
    • Line 79: warning: exported method PullRequest.FailedContexts should have comment or be unexported (golint)
    • Line 92: warning: exported method PullRequest.ColoredTitle should have comment or be unexported (golint)
    • Line 102: warning: exported method PullRequest.ColoredReviewDecision should have comment or be unexported (golint)
    • Line 114: warning: exported method PullRequest.TrimmedTitle should have comment or be unexported (golint)
    • Line 121: warning: exported method PullRequest.MergeableString should have comment or be unexported (golint)
    • Line 131: warning: exported method PullRequest.PullsString should have comment or be unexported (golint)
    • Line 136: warning: exported method PullRequest.HasLabel should have comment or be unexported (golint)
    • Line 145: warning: exported method PullRequest.HasContext should have comment or be unexported (golint)
    • Line 157: warning: exported type Repository should have comment or be unexported (golint)
    • Line 161: warning: exported type Author should have comment or be unexported (golint)
    • Line 165: warning: exported type Labels should have comment or be unexported (golint)
    • Line 169: warning: exported type Label should have comment or be unexported (golint)
    • Line 173: warning: exported type Commits should have comment or be unexported (golint)
    • Line 177: warning: exported type CommitEntry should have comment or be unexported (golint)
    • Line 181: warning: exported type Commit should have comment or be unexported (golint)
    • Line 185: warning: exported type StatusCheckRollup should have comment or be unexported (golint)
    • Line 190: warning: exported type StatusContext should have comment or be unexported (golint)
    • Line 194: warning: exported type Context should have comment or be unexported (golint)
    • Line 224: warning: exported type ByPullsString should have comment or be unexported (golint)
    • dx/pkg/httpmock/registry.go
    • Line 9: warning: exported type Registry should have comment or be unexported (golint)
    • Line 15: warning: exported method Registry.Register should have comment or be unexported (golint)
    • Line 22: warning: exported type Testing should have comment or be unexported (golint)
    • Line 26: warning: exported method Registry.Verify should have comment or be unexported (golint)
    • dx/pkg/domain/rebase.go
    • Line 13: warning: exported type Rebase should have comment or be unexported (golint)
    • Line 24: warning: comment on exported function NewRebase should be of the form "NewRebase ..." (golint)
    • dx/pkg/util/file.go
    • Line 32: warning: exported function ReadFile should have comment or be unexported (golint)
    • Line 46: warning: exported function HomeDir should have comment or be unexported (golint)
    • Line 57: warning: exported function ConfigDir should have comment or be unexported (golint)
    • Line 63: warning: exported function CreateConfigPath should have comment or be unexported (golint)
    • Line 69: warning: exported function GhConfigDir should have comment or be unexported (golint)
    • Line 75: warning: exported function DxConfigFile should have comment or be unexported (golint)
    • Line 79: warning: comment on exported function CopyFile should be of the form "CopyFile ..." (golint)
    • Line 119: warning: comment on exported function CopyDir should be of the form "CopyDir ..." (golint)
    • dx/pkg/table/padding.go
    • Line 16: warning: exported function Pad should have comment or be unexported (golint)
    • Line 27: warning: exported function PadRight should have comment or be unexported (golint)
    • Line 35: warning: exported function PadLeft should have comment or be unexported (golint)
    • Line 43: warning: exported function PadCenter should have comment or be unexported (golint)
    • dx/pkg/cmd/upgradecmd/upgrade_cli.go
    • Line 31: warning: exported type Release should have comment or be unexported (golint)
    • Line 38: warning: exported type ReleaseAsset should have comment or be unexported (golint)
    • Line 43: warning: exported type UpgradeCliCmd should have comment or be unexported (golint)
    • dx/pkg/api/config.go
    • Line 12: warning: exported function ConfigFile should have comment or be unexported (golint)
    • Line 16: warning: exported function HostsFile should have comment or be unexported (golint)
    • Line 20: warning: exported function ParseDefaultConfig should have comment or be unexported (golint)
    • dx/pkg/cmd/namespacecmd/namespace.go
    • Line 10: warning: exported type NamespaceCmd should have comment or be unexported (golint)
    • Line 15: warning: exported function NewNamespaceCmd should have comment or be unexported (golint)
    • Line 36: warning: exported method NamespaceCmd.Run should have comment or be unexported (golint)
    • dx/pkg/table/table.go
    • Line 12: warning: exported type Table should have comment or be unexported (golint)
    • Line 20: warning: exported function NewTable should have comment or be unexported (golint)
    • Line 37: warning: exported method Table.Render 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!