|
@@ -1,6 +1,10 @@
|
|
|
package sizer
|
|
|
|
|
|
-import "log"
|
|
|
+import (
|
|
|
+ "log"
|
|
|
+
|
|
|
+ "github.com/fatih/color"
|
|
|
+)
|
|
|
|
|
|
// Debug is a global bool to toggle debugging messages.
|
|
|
var Debug bool
|
|
@@ -59,3 +63,15 @@ var Console console
|
|
|
func init() {
|
|
|
Console.SetFlags(0)
|
|
|
}
|
|
|
+
|
|
|
+// Red is a function that, given a string, returns the string
|
|
|
+// in ANSI red foreground color.
|
|
|
+var Red = color.New(color.FgRed).SprintFunc()
|
|
|
+
|
|
|
+// Green is a function that, given a string, returns the string
|
|
|
+// in ANSI green foreground color.
|
|
|
+var Green = color.New(color.FgGreen).SprintFunc()
|
|
|
+
|
|
|
+// Cyan is a function that, given a string, returns the string
|
|
|
+// in ANSI cyan foreground color.
|
|
|
+var Cyan = color.New(color.FgCyan).SprintFunc()
|