mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-05 18:24:07 +00:00
Merge pull request #130033 from ardaguclu/completion-use-restclientgetter
Add completion in kubectl debug
This commit is contained in:
commit
990b02bf39
@ -389,6 +389,8 @@ func NewKubectlCommand(o KubectlOptions) *cobra.Command {
|
|||||||
// Avoid import cycle by setting ValidArgsFunction here instead of in NewCmdGet()
|
// Avoid import cycle by setting ValidArgsFunction here instead of in NewCmdGet()
|
||||||
getCmd := get.NewCmdGet("kubectl", f, o.IOStreams)
|
getCmd := get.NewCmdGet("kubectl", f, o.IOStreams)
|
||||||
getCmd.ValidArgsFunction = utilcomp.ResourceTypeAndNameCompletionFunc(f)
|
getCmd.ValidArgsFunction = utilcomp.ResourceTypeAndNameCompletionFunc(f)
|
||||||
|
debugCmd := debug.NewCmdDebug(f, o.IOStreams)
|
||||||
|
debugCmd.ValidArgsFunction = utilcomp.ResourceTypeAndNameCompletionFunc(f)
|
||||||
|
|
||||||
groups := templates.CommandGroups{
|
groups := templates.CommandGroups{
|
||||||
{
|
{
|
||||||
@ -440,7 +442,7 @@ func NewKubectlCommand(o KubectlOptions) *cobra.Command {
|
|||||||
proxyCmd,
|
proxyCmd,
|
||||||
cp.NewCmdCp(f, o.IOStreams),
|
cp.NewCmdCp(f, o.IOStreams),
|
||||||
auth.NewCmdAuth(f, o.IOStreams),
|
auth.NewCmdAuth(f, o.IOStreams),
|
||||||
debug.NewCmdDebug(f, o.IOStreams),
|
debugCmd,
|
||||||
events.NewCmdEvents(f, o.IOStreams),
|
events.NewCmdEvents(f, o.IOStreams),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user