console

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2025 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Black   = color("\033[1;30m%s\033[0m")
	Red     = color("\033[1;31m%s\033[0m")
	Green   = color("\033[1;32m%s\033[0m")
	Yellow  = color("\033[1;33m%s\033[0m")
	Purple  = color("\033[1;34m%s\033[0m")
	Magenta = color("\033[1;35m%s\033[0m")
	Teal    = color("\033[1;36m%s\033[0m")
	White   = color("\033[1;37m%s\033[0m")
)
View Source
var Std = New()

Functions

This section is empty.

Types

type Console

type Console struct{}

func New

func New() *Console

func (*Console) Confirm

func (c *Console) Confirm(s string) bool

func (*Console) Error

func (c *Console) Error(message string)

func (*Console) ErrorLn

func (c *Console) ErrorLn(message string)

func (*Console) Errorf

func (c *Console) Errorf(message string, a ...any)

func (*Console) Fatal

func (c *Console) Fatal(err error)

func (*Console) Info

func (c *Console) Info(message string)

func (*Console) InfoLn

func (c *Console) InfoLn(message string)

func (*Console) Infof

func (c *Console) Infof(message string, a ...any)

func (*Console) NumberPlural

func (c *Console) NumberPlural(count int, one, many string) string

func (*Console) Success

func (c *Console) Success(message string)

func (*Console) SuccessLn

func (c *Console) SuccessLn(message string)

func (*Console) Successf

func (c *Console) Successf(message string, a ...any)

func (*Console) Warn

func (c *Console) Warn(message string)

func (*Console) WarnLn

func (c *Console) WarnLn(message string)

func (*Console) Warnf

func (c *Console) Warnf(message string, a ...any)

type Dummy

type Dummy struct {
	// contains filtered or unexported fields
}

func NewDummy

func NewDummy(confirm bool) *Dummy

func (*Dummy) Confirm

func (c *Dummy) Confirm(s string) bool

func (*Dummy) Error

func (c *Dummy) Error(message string)

func (*Dummy) ErrorLn

func (c *Dummy) ErrorLn(message string)

func (*Dummy) Errorf

func (c *Dummy) Errorf(message string, a ...any)

func (*Dummy) Fatal

func (c *Dummy) Fatal(err error)

func (*Dummy) Info

func (c *Dummy) Info(message string)

func (*Dummy) InfoLn

func (c *Dummy) InfoLn(message string)

func (*Dummy) Infof

func (c *Dummy) Infof(message string, a ...any)

func (*Dummy) NumberPlural

func (c *Dummy) NumberPlural(count int, one, many string) string

func (*Dummy) Success

func (c *Dummy) Success(message string)

func (*Dummy) SuccessLn

func (c *Dummy) SuccessLn(message string)

func (*Dummy) Successf

func (c *Dummy) Successf(message string, a ...any)

func (*Dummy) Warn

func (c *Dummy) Warn(message string)

func (*Dummy) WarnLn

func (c *Dummy) WarnLn(message string)

func (*Dummy) Warnf

func (c *Dummy) Warnf(message string, a ...any)

Jump to

Keyboard shortcuts

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