{"modulePath":"github.com/rancher/docker-cli","version":"v0.0.0-20190201110649-896ff57b300c","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package cli\n\n## Functions\n\n```go\nfunc DisableFlagsInUseLine(cmd *cobra.Command)\n```\nDisableFlagsInUseLine sets the DisableFlagsInUseLine flag on all commands within the tree rooted at cmd.\n\n```go\nfunc ExactArgs(number int) cobra.PositionalArgs\n```\nExactArgs returns an error if there is not the exact number of args\n\n```go\nfunc FlagErrorFunc(cmd *cobra.Command, err error) error\n```\nFlagErrorFunc prints an error message which matches the format of the docker/cli/cli error messages\n\n```go\nfunc NoArgs(cmd *cobra.Command, args []string) error\n```\nNoArgs validates args and returns an error if there are any args\n\n```go\nfunc RequiresMaxArgs(max int) cobra.PositionalArgs\n```\nRequiresMaxArgs returns an error if there is not at most max args\n\n```go\nfunc RequiresMinArgs(min int) cobra.PositionalArgs\n```\nRequiresMinArgs returns an error if there is not at least min args\n\n```go\nfunc RequiresRangeArgs(min int, max int) cobra.PositionalArgs\n```\nRequiresRangeArgs returns an error if there is not at least min args and at most max args\n\n```go\nfunc SetupPluginRootCommand(rootCmd *cobra.Command) (*cliflags.ClientOptions, *pflag.FlagSet)\n```\nSetupPluginRootCommand sets default usage, help and error handling for a plugin root command.\n\n```go\nfunc SetupRootCommand(rootCmd *cobra.Command) (*cliflags.ClientOptions, *pflag.FlagSet, *cobra.Command)\n```\nSetupRootCommand sets default usage, help, and error handling for the root command.\n\n```go\nfunc VisitAll(root *cobra.Command, fn func(*cobra.Command))\n```\nVisitAll will traverse all commands from the root. This is different from the VisitAll of cobra.Command where only parents are checked.\n\n## Types\n\n```go\ntype Errors []error\n```\nErrors is a list of errors. Useful in a loop if you don't want to return the error right away and you want to display after the loop, all the errors that happened during the loop.\n\n```go\nfunc (errList Errors) Error() string\n```\n\n```go\ntype StatusError struct {\n\tStatus     string\n\tStatusCode int\n}\n```\nStatusError reports an unsuccessful exit by a command.\n\n```go\nfunc (e StatusError) Error() string\n```\n\n","path":"github.com/rancher/docker-cli/cli","name":"cli","synopsis":"","isRedistributable":true}
