From ea647327a9e5a545b6a115cf777a0ae8faf30cb0 Mon Sep 17 00:00:00 2001 From: Rafal Pieniazek Date: Thu, 19 Aug 2021 10:25:41 +0200 Subject: [PATCH 1/2] Update CLI flags * update CLI flags with appropriate aliases. --- app.go | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/app.go b/app.go index 9e7a7a5..2326124 100644 --- a/app.go +++ b/app.go @@ -38,26 +38,44 @@ func CreateFlags() []cli.Flag { appFlags := []cli.Flag{ &cli.StringFlag{ - Name: "section, s", - Value: "default", + Name: "section", + Value: "default", + Aliases: []string{ + "s", + }, Usage: "`NAME` of section to use from credentials file", EnvVars: []string{string(edgegrid.EnvVarEdgercSection)}, }, &cli.StringFlag{ - Name: "config, c", - Value: HomeDir(), + Name: "config", + Value: HomeDir(), + Aliases: []string{ + "c", + }, Usage: "Location of the credentials `FILE`", EnvVars: []string{string(edgegrid.EnvVarEdgercPath)}, }, &cli.StringFlag{ Name: "debug", Value: "", - Usage: "Debug Level", + Usage: "(Deprecated) Debug Level", + EnvVars: []string{string(edgegrid.EnvVarDebugLevelSection)}, + }, + &cli.StringFlag{ + Name: "verbosity", + Value: "", + Aliases: []string{ + "v", + }, + Usage: "Defines level of messages being displayed ( info,warning,error,trace,debug )", EnvVars: []string{string(edgegrid.EnvVarDebugLevelSection)}, }, &cli.StringFlag{ - Name: "account-switch-key, ask", + Name: "account-switch-key", Value: "", + Aliases: []string{ + "ask", + }, Usage: "Account Switch Key (ASK)", }, } From 665b0277f0b7be17e409621343244ded53f0a463 Mon Sep 17 00:00:00 2001 From: Rafal Pieniazek Date: Thu, 19 Aug 2021 10:50:28 +0200 Subject: [PATCH 2/2] Update app.go --- app.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app.go b/app.go index 2326124..16b428f 100644 --- a/app.go +++ b/app.go @@ -10,7 +10,7 @@ import ( //CreateNewApp returns new application func CreateNewApp(appShortName, usage, version string) *cli.App { - + app := &cli.App{ Name: inCLI(appShortName), Usage: usage, @@ -19,7 +19,7 @@ func CreateNewApp(appShortName, usage, version string) *cli.App { Authors: []*cli.Author{ &cli.Author{ Name: "Rafal Pieniazek", - Email: "-", + Email: "https://mailhide.io/e/XZ3bESkk", }, &cli.Author{ Name: "Petr Artamonov",