color

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Reset   = "\033[0m"
	Red     = "\033[31m"
	Green   = "\033[32m"
	Yellow  = "\033[33m"
	Blue    = "\033[34m"
	Magenta = "\033[35m"
	Cyan    = "\033[36m"
	White   = "\033[37m"

	// Bold variants
	BoldRed     = "\033[1;31m"
	BoldGreen   = "\033[1;32m"
	BoldYellow  = "\033[1;33m"
	BoldBlue    = "\033[1;34m"
	BoldMagenta = "\033[1;35m"
	BoldCyan    = "\033[1;36m"
	BoldWhite   = "\033[1;37m"
)

ANSI color codes

Variables

This section is empty.

Functions

func Error

func Error(format string, args ...any)

Error prints a red error message

func Highlight

func Highlight(format string, args ...any)

Highlight prints a magenta highlighted message

func Info

func Info(format string, args ...any)

Info prints a cyan info message

func Sprintf

func Sprintf(c, format string, args ...any) string

Sprintf returns a colored string

func Success

func Success(format string, args ...any)

Success prints a green success message

func Warning

func Warning(format string, args ...any)

Warning prints a yellow warning message

Types

This section is empty.

Jump to

Keyboard shortcuts

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