MCPcopy
hub / github.com/spf13/cobra / Print

Method Print

command.go:1435–1437  ·  view source on GitHub ↗

Print is a convenience method to Print to the defined output, fallback to Stderr if not set.

(i ...interface{})

Source from the content-addressed store, hash-verified

1433
1434// Print is a convenience method to Print to the defined output, fallback to Stderr if not set.
1435func (c *Command) Print(i ...interface{}) {
1436 fmt.Fprint(c.OutOrStderr(), i...)
1437}
1438
1439// Println is a convenience method to Println to the defined output, fallback to Stderr if not set.
1440func (c *Command) Println(i ...interface{}) {

Callers 8

TestSetHelpCommandFunction · 0.95
PrintlnMethod · 0.95
PrintfMethod · 0.95
ParseFlagsMethod · 0.95
preExecHookFunction · 0.80
ExampleGenManFunction · 0.80

Calls 1

OutOrStderrMethod · 0.95

Tested by 4

TestSetHelpCommandFunction · 0.76
ExampleGenManFunction · 0.64