diff options
author | Paul Holzinger <pholzing@redhat.com> | 2022-06-21 16:57:49 +0200 |
---|---|---|
committer | Paul Holzinger <pholzing@redhat.com> | 2022-06-21 17:17:06 +0200 |
commit | 050693b2e773e6334dc200fc0c819e3829ac400d (patch) | |
tree | 97a1614b3f622023c5282141157ebdb36d9e7678 /cmd | |
parent | c8032b99117068018d21f3e1773cdb070fa46279 (diff) | |
download | podman-050693b2e773e6334dc200fc0c819e3829ac400d.tar.gz podman-050693b2e773e6334dc200fc0c819e3829ac400d.tar.bz2 podman-050693b2e773e6334dc200fc0c819e3829ac400d.zip |
bump github.com/spf13/cobra from 1.4.0 to 1.5.0
Update cobra to latest version. Remove workaround for podman -h.
Also regenerate the completion scripts.
[NO NEW TESTS NEEDED]
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/podman/main.go | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/cmd/podman/main.go b/cmd/podman/main.go index c6ba69e94..929c8a757 100644 --- a/cmd/podman/main.go +++ b/cmd/podman/main.go @@ -1,7 +1,6 @@ package main import ( - "errors" "fmt" "os" @@ -27,7 +26,6 @@ import ( "github.com/containers/storage/pkg/reexec" "github.com/sirupsen/logrus" "github.com/spf13/cobra" - "github.com/spf13/pflag" ) func main() { @@ -103,13 +101,6 @@ func parseCommands() *cobra.Command { } func flagErrorFuncfunc(c *cobra.Command, e error) error { - // cobra compares via == and not errors.Is so we cannot wrap that error. - // This is required to make podman -h work. - // This can be removed once https://github.com/spf13/cobra/pull/1730 - // is merged and vendored into podman. - if errors.Is(e, pflag.ErrHelp) { - return e - } e = fmt.Errorf("%w\nSee '%s --help'", e, c.CommandPath()) return e } |