Skip to content

Commit f2d736e

Browse files
committed
cmd: remove paramcompletion option which is shipped enabled by default
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
1 parent bcca2ac commit f2d736e

2 files changed

Lines changed: 25 additions & 30 deletions

File tree

cmd/set.go

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -30,20 +30,19 @@ func init() {
3030
Name: "set",
3131
Help: "Configures options for cmk",
3232
SubCommands: map[string][]string{
33-
"prompt": {"🐵", "🐱", "random"},
34-
"asyncblock": {"true", "false"},
35-
"timeout": {"600", "1800", "3600"},
36-
"output": {"json", "text", "table", "column", "csv"},
37-
"profile": {},
38-
"url": {},
39-
"username": {},
40-
"password": {},
41-
"domain": {},
42-
"apikey": {},
43-
"secretkey": {},
44-
"paramcompletion": {"true", "false"},
45-
"verifycert": {"true", "false"},
46-
"debug": {"true", "false"},
33+
"prompt": {"🐵", "🐱", "random"},
34+
"asyncblock": {"true", "false"},
35+
"timeout": {"600", "1800", "3600"},
36+
"output": {"json", "text", "table", "column", "csv"},
37+
"profile": {},
38+
"url": {},
39+
"username": {},
40+
"password": {},
41+
"domain": {},
42+
"apikey": {},
43+
"secretkey": {},
44+
"verifycert": {"true", "false"},
45+
"debug": {"true", "false"},
4746
},
4847
Handle: func(r *Request) error {
4948
if len(r.Args) < 1 {

config/config.go

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,12 @@ type ServerProfile struct {
5454

5555
// Core block describes common options for the CLI
5656
type Core struct {
57-
Prompt string `ini:"prompt"`
58-
AsyncBlock bool `ini:"asyncblock"`
59-
Timeout int `ini:"timeout"`
60-
Output string `ini:"output"`
61-
ParamCompletion bool `ini:"paramcompletion"`
62-
VerifyCert bool `ini:"verifycert"`
63-
ProfileName string `ini:"profile"`
57+
Prompt string `ini:"prompt"`
58+
AsyncBlock bool `ini:"asyncblock"`
59+
Timeout int `ini:"timeout"`
60+
Output string `ini:"output"`
61+
VerifyCert bool `ini:"verifycert"`
62+
ProfileName string `ini:"profile"`
6463
}
6564

6665
// Config describes CLI config file and default options
@@ -107,13 +106,12 @@ func getDefaultConfigDir() string {
107106

108107
func defaultCoreConfig() Core {
109108
return Core{
110-
Prompt: "🐱",
111-
AsyncBlock: true,
112-
Timeout: 1800,
113-
Output: JSON,
114-
ParamCompletion: true,
115-
VerifyCert: true,
116-
ProfileName: "localcloud",
109+
Prompt: "🐱",
110+
AsyncBlock: true,
111+
Timeout: 1800,
112+
Output: JSON,
113+
VerifyCert: true,
114+
ProfileName: "localcloud",
117115
}
118116
}
119117

@@ -304,8 +302,6 @@ func (c *Config) UpdateConfig(key string, value string, update bool) {
304302
c.ActiveProfile.APIKey = value
305303
case "secretkey":
306304
c.ActiveProfile.SecretKey = value
307-
case "paramcompletion":
308-
c.Core.ParamCompletion = value == "true"
309305
case "verifycert":
310306
c.Core.VerifyCert = value == "true"
311307
case "debug":

0 commit comments

Comments
 (0)