From f468d10feff8f8cfa98e6a968e12508e95db731c Mon Sep 17 00:00:00 2001 From: CrazyMax Date: Tue, 18 Jan 2022 16:53:34 +0100 Subject: [PATCH] yaml: root command should also be removed for cli (non-plugin) Signed-off-by: CrazyMax --- clidocstool_yaml.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clidocstool_yaml.go b/clidocstool_yaml.go index 55cd49d..5af61ba 100644 --- a/clidocstool_yaml.go +++ b/clidocstool_yaml.go @@ -367,7 +367,7 @@ func (c *Client) loadLongDescription(parentCmd *cobra.Command) error { } } name := cmd.CommandPath() - if i := strings.Index(name, " "); c.plugin && i >= 0 { + if i := strings.Index(name, " "); i >= 0 { // remove root command / binary name name = name[i+1:] }