print

package
v1.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 9, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Yellow    = color.New(color.FgHiYellow, color.Bold).SprintFunc()
	Green     = color.New(color.FgHiGreen, color.Bold).SprintFunc()
	Blue      = color.New(color.FgHiBlue, color.Bold).SprintFunc()
	Cyan      = color.New(color.FgCyan, color.Bold, color.Underline).SprintFunc()
	Red       = color.New(color.FgHiRed, color.Bold).Add(color.Italic).SprintFunc()
	White     = color.New(color.FgWhite).SprintFunc()
	WhiteBold = color.New(color.FgWhite, color.Bold).SprintFunc()
)

Functions

func EnableJSONFormat

func EnableJSONFormat()

func FailureStatusEvent

func FailureStatusEvent(w io.Writer, fmtstr string, a ...interface{})

FailureStatusEvent reports on a failure event.

func InfoStatusEvent

func InfoStatusEvent(w io.Writer, fmtstr string, a ...interface{})

InfoStatusEvent reports status information on an event.

func PendingStatusEvent

func PendingStatusEvent(w io.Writer, fmtstr string, a ...interface{})

PendingStatusEvent reports on a pending event.

func Spinner

func Spinner(w io.Writer, fmtstr string, a ...interface{}) (func(msg string), func(result Result))

func SuccessStatusEvent

func SuccessStatusEvent(w io.Writer, fmtstr string, a ...interface{})

SuccessStatusEvent reports on a success event.

func WarningStatusEvent

func WarningStatusEvent(w io.Writer, fmtstr string, a ...interface{})

WarningStatusEvent reports on a failure event.

Types

type Result

type Result bool
const (
	Success Result = true
	Failure Result = false
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL