diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-11-08 18:23:17 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-08 18:23:17 +0100 |
commit | abfec8144a57265e644dbfec93f5b6201b7da945 (patch) | |
tree | eb4eab305260adce08c6071e03a1fb858b385b14 /cmd/podman | |
parent | 22ef488d246effddbb3f390dd3fd048dc0f5fe82 (diff) | |
parent | 756dda298c76b54a4401b7497bbff297dcf4014f (diff) | |
download | podman-abfec8144a57265e644dbfec93f5b6201b7da945.tar.gz podman-abfec8144a57265e644dbfec93f5b6201b7da945.tar.bz2 podman-abfec8144a57265e644dbfec93f5b6201b7da945.zip |
Merge pull request #11953 from markusthoemmes/help-default
Display help text on empty subcommand by default
Diffstat (limited to 'cmd/podman')
-rw-r--r-- | cmd/podman/validate/args.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/podman/validate/args.go b/cmd/podman/validate/args.go index fc07a6acc..6b5425a69 100644 --- a/cmd/podman/validate/args.go +++ b/cmd/podman/validate/args.go @@ -27,7 +27,8 @@ func SubCommandExists(cmd *cobra.Command, args []string) error { } return errors.Errorf("unrecognized command `%[1]s %[2]s`\n\nDid you mean this?\n\t%[3]s\n\nTry '%[1]s --help' for more information.", cmd.CommandPath(), args[0], strings.Join(suggestions, "\n\t")) } - return errors.Errorf("missing command '%[1]s COMMAND'\nTry '%[1]s --help' for more information.", cmd.CommandPath()) + cmd.Help() + return errors.Errorf("missing command '%[1]s COMMAND'", cmd.CommandPath()) } // IDOrLatestArgs used to validate a nameOrId was provided or the "--latest" flag |