From 8b660aface0cf9f37192798f08faa1643a4be1a9 Mon Sep 17 00:00:00 2001 From: Thomas Piccirello Date: Wed, 7 Jul 2021 11:55:26 -0700 Subject: [PATCH] chore: update comments --- pkg/cmd/configure.go | 2 +- pkg/cmd/root.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/cmd/configure.go b/pkg/cmd/configure.go index 7ce7121a..397df055 100644 --- a/pkg/cmd/configure.go +++ b/pkg/cmd/configure.go @@ -230,7 +230,7 @@ var configureResetCmd = &cobra.Command{ }, } -// currentConfigOptionsValidArgs the options currently in use in the current scope +// configOptionsValidArgs all possible config options func configOptionsValidArgs(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) { persistentValidArgsFunction(cmd) diff --git a/pkg/cmd/root.go b/pkg/cmd/root.go index 48051781..1ef2f1c6 100644 --- a/pkg/cmd/root.go +++ b/pkg/cmd/root.go @@ -126,6 +126,7 @@ func checkVersion(command string) { // persistentValidArgsFunction Cobra parses flags after executing ValidArgsFunction, so we must manually initialize flags func persistentValidArgsFunction(cmd *cobra.Command) { + // more info https://github.com/spf13/cobra/issues/1291 loadFlags(cmd) }