MCPcopy
hub / github.com/cloudfoundry/cli / viewTarget

Method viewTarget

command/v7/api_command.go:84–93  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

82}
83
84func (cmd *APICommand) viewTarget() error {
85 if cmd.Config.Target() == "" {
86 cmd.UI.DisplayText("No API endpoint set. Use '{{.Name}}' to set an endpoint", map[string]interface{}{
87 "Name": "cf api",
88 })
89 return nil
90 }
91
92 return cmd.displayTarget()
93}
94
95func (cmd *APICommand) displayTarget() error {
96 cmd.UI.DisplayKeyValueTable("", [][]string{

Callers 1

ExecuteMethod · 0.95

Calls 3

displayTargetMethod · 0.95
TargetMethod · 0.65
DisplayTextMethod · 0.65

Tested by

no test coverage detected