diff --git a/cmd/mapkubeapis/map.go b/cmd/mapkubeapis/map.go index 14209ec..8a5ab18 100644 --- a/cmd/mapkubeapis/map.go +++ b/cmd/mapkubeapis/map.go @@ -41,7 +41,7 @@ var ( settings *EnvSettings ) -func newMapCmd(_ io.Writer, args []string) *cobra.Command { +func newMapCmd(_ io.Writer) *cobra.Command { cmd := &cobra.Command{ Use: "mapkubeapis [flags] RELEASE", Short: "Map release deprecated or removed Kubernetes APIs in-place", @@ -65,10 +65,6 @@ func newMapCmd(_ io.Writer, args []string) *cobra.Command { flags := cmd.PersistentFlags() flags.ParseErrorsWhitelist.UnknownFlags = true - err := flags.Parse(args) - if err != nil { - return nil - } settings = new(EnvSettings) diff --git a/cmd/mapkubeapis/map_kube_apis.go b/cmd/mapkubeapis/map_kube_apis.go index a888bea..da2eaf7 100644 --- a/cmd/mapkubeapis/map_kube_apis.go +++ b/cmd/mapkubeapis/map_kube_apis.go @@ -21,7 +21,7 @@ import ( ) func main() { - mapCmd := newMapCmd(os.Stdout, os.Args[1:]) + mapCmd := newMapCmd(os.Stdout) if err := mapCmd.Execute(); err != nil { os.Exit(1)