Documentation ¶
Overview ¶
Package util implements utility routines for printing messages, warnings, and errors.
Index ¶
- Variables
- func LoadStringPairs(csvPath string) ([][2]string, error)
- func PrintDebug(format string, args ...interface{})
- func PrintError(err error, format string, args ...interface{})
- func PrintFatalError(err error, format string, args ...interface{})
- func PrintMessage(format string, args ...interface{})
- func PrintVerbose(format string, args ...interface{})
- func PrintWarning(format string, args ...interface{})
Constants ¶
This section is empty.
Variables ¶
View Source
var Debug bool
View Source
var Verbose bool
Functions ¶
func LoadStringPairs ¶ added in v0.2.0
LoadStringPairs loads string pairs from a CSV file, where each line is two comma separated strings.
func PrintDebug ¶ added in v0.2.0
func PrintDebug(format string, args ...interface{})
PrintDebug prints a message to stdout if the Debug flag is set.
func PrintError ¶
PrintError prints a error message to stderr.
func PrintFatalError ¶
PrintFatalError prints a error message to stderr and exits.
func PrintMessage ¶
func PrintMessage(format string, args ...interface{})
PrintMessage prints a message to stdout.
func PrintVerbose ¶ added in v0.2.0
func PrintVerbose(format string, args ...interface{})
PrintVerbose prints a message to stdout if either the Verbose or Debug flag is set.
func PrintWarning ¶
func PrintWarning(format string, args ...interface{})
PrintWarning prints a warning to stderr.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.