Code Review
/
src
/
xds
/
xds-cli.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Add gitreview file for jellyfish branch
[src/xds/xds-cli.git]
/
cmd-target.go
diff --git
a/cmd-target.go
b/cmd-target.go
index
33b757d
..
6140755
100644
(file)
--- a/
cmd-target.go
+++ b/
cmd-target.go
@@
-165,7
+165,7
@@
func targetsList(ctx *cli.Context) error {
}
func targetsGet(ctx *cli.Context) error {
}
func targetsGet(ctx *cli.Context) error {
- id := GetID(ctx)
+ id := GetID(ctx
, "XDS_TARGET_ID"
)
if id == "" {
return cli.NewExitError("id parameter or option must be set", 1)
}
if id == "" {
return cli.NewExitError("id parameter or option must be set", 1)
}
@@
-254,7
+254,7
@@
func targetsAdd(ctx *cli.Context) error {
func targetsRemove(ctx *cli.Context) error {
var res xaapiv1.TargetConfig
func targetsRemove(ctx *cli.Context) error {
var res xaapiv1.TargetConfig
- id := GetID(ctx)
+ id := GetID(ctx
, "XDS_TARGET_ID"
)
if id == "" {
return cli.NewExitError("id parameter or option must be set", 1)
}
if id == "" {
return cli.NewExitError("id parameter or option must be set", 1)
}
@@
-543,7
+543,7
@@
func GetTargetAndTerminalIDs(ctx *cli.Context, useFirstFree bool) (*xaapiv1.Targ
}
// Allow to create a new terminal when only target id is set
}
// Allow to create a new terminal when only target id is set
- idArg = GetIDName(ctx, "id")
+ idArg = GetIDName(ctx, "id"
, "XDS_TARGET_ID"
)
if idArg == "" {
return nil, nil, fmt.Errorf("id or termId argument must be set")
}
if idArg == "" {
return nil, nil, fmt.Errorf("id or termId argument must be set")
}