From a16ca12f8a233c695532cbf1b3bc23c3ffff8d76 Mon Sep 17 00:00:00 2001 From: Andreas Ulm Date: Thu, 2 May 2019 08:01:00 +0200 Subject: [PATCH] added description to explain reason for global variables Signed-off-by: Andreas Ulm --- cmd/flags.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cmd/flags.go b/cmd/flags.go index 6f41a03..2d15540 100644 --- a/cmd/flags.go +++ b/cmd/flags.go @@ -39,7 +39,9 @@ var OutputFlag = cli.StringFlag{ } // DefaultFlags defines flags that should be available -// for all subcommands +// for all subcommands and appended to the flags of the +// subcommand to work around issue: +// https://github.com/urfave/cli/issues/585 var DefaultFlags = []cli.Flag{ LoginFlag, OutputFlag, @@ -47,6 +49,8 @@ var DefaultFlags = []cli.Flag{ // RepoDefaultFlags defines flags that should be available // for all subcommands working with dedicated repositories +// to work around issue: +// https://github.com/urfave/cli/issues/585 var RepoDefaultFlags = append([]cli.Flag{ RepoFlag, }, DefaultFlags...)