Documentation
¶
Overview ¶
Package out provides out utilities for the Inertia CLI
Index ¶
- Constants
- func Fatal(args ...interface{})
- func Fatalf(format string, args ...interface{})
- func FormatRemoteDetails(remote cfg.Remote) string
- func FormatStatus(s *api.DeploymentStatus) string
- func Fprintf(out io.Writer, format string, args ...interface{})
- func Print(args ...interface{})
- func Printf(format string, args ...interface{})
- func Println(args ...interface{})
- func Sprintf(format string, args ...interface{}) string
- func WithColor() bool
- func WithEmoji() bool
- type ColorTraits
- type Colored
- type Colorer
Constants ¶
View Source
const ( // EnvEmojiToggle is the environment variable used to disable or enable emoji EnvEmojiToggle = "INERTIA_EMOJI" // EnvColorToggle is the environment variable used to disable or enable colors EnvColorToggle = "INERTIA_COLOR" )
Variables ¶
This section is empty.
Functions ¶
func Fatal ¶
func Fatal(args ...interface{})
Fatal is a wrapper around fmt.Print that exits with status 1
func Fatalf ¶
func Fatalf(format string, args ...interface{})
Fatalf is a wrapper around out.Printf that exits with status 1
func FormatRemoteDetails ¶
FormatRemoteDetails prints the given remote configuration
func FormatStatus ¶
func FormatStatus(s *api.DeploymentStatus) string
FormatStatus prints the given deployment status
Types ¶
type ColorTraits ¶
ColorTraits denotes colour customizations
const ( // RD = red RD ColorTraits = ColorTraits(color.FgRed) // CY = cyan CY ColorTraits = ColorTraits(color.FgCyan) // GR = green GR ColorTraits = ColorTraits(color.FgGreen) // YE = yellow YE ColorTraits = ColorTraits(color.FgYellow) // BO = bold BO ColorTraits = ColorTraits(color.Bold) // UL = underline UL ColorTraits = ColorTraits(color.Underline) )
type Colored ¶
type Colored struct {
// contains filtered or unexported fields
}
Colored converts a given string to the given colour
type Colorer ¶
type Colorer struct {
// contains filtered or unexported fields
}
Colorer wraps fatih/color.Color
func NewColorer ¶
func NewColorer(traits ...ColorTraits) *Colorer
NewColorer instantiates a new Colorer
Click to show internal directories.
Click to hide internal directories.