Documentation ¶
Overview ¶
Package cli provides a client SDK for outputting data to a terminal in multiple formats
Index ¶
- Constants
- type CLIClient
- func (c *CLIClient) FetchAndOutput(f func() (apiresponse.TabbyPrinter, error)) error
- func (c *CLIClient) OutputObject(tabby_printer apiresponse.TabbyPrinter) error
- func (c *CLIClient) PromptForAttribute() (models.Attribute, error)
- func (c *CLIClient) PromptForAttributes() (attributes []models.Attribute, err error)
- func (c *CLIClient) PromptForTags() (tags []models.Tag, err error)
Constants ¶
View Source
const ( OutputStyleJSON = "json" OutputStyleJSONPretty = "json_pretty" OutputStyleTabby = "tabby" // Default )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CLIClient ¶ added in v0.58.0
func (*CLIClient) FetchAndOutput ¶ added in v0.60.0
func (c *CLIClient) FetchAndOutput(f func() (apiresponse.TabbyPrinter, error)) error
func (*CLIClient) OutputObject ¶ added in v0.58.0
func (c *CLIClient) OutputObject(tabby_printer apiresponse.TabbyPrinter) error
OutputObject prints indented or unindented json, or an ascii table (tabby) (depending on *CLIClient#OutputStyle) to stdout
func (*CLIClient) PromptForAttribute ¶ added in v0.58.0
func (*CLIClient) PromptForAttributes ¶ added in v0.72.0
Click to show internal directories.
Click to hide internal directories.