From 4420c209339d8369c6b6cb2fbac5ffe92b74e257 Mon Sep 17 00:00:00 2001 From: Ryan Cavicchioni Date: Tue, 24 Mar 2020 09:14:22 -0500 Subject: [PATCH] a full ANSI color library is not required yet --- cmd/lume.go | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/cmd/lume.go b/cmd/lume.go index 43d761b..4fbaa9b 100644 --- a/cmd/lume.go +++ b/cmd/lume.go @@ -6,8 +6,6 @@ import ( "os" "strconv" "time" - - fc "github.com/fatih/color" ) import ( @@ -221,10 +219,10 @@ func PrintLights(lights []lifx.Light) { } func PowerColor(s string) string { - color := fc.New(fc.FgRed).SprintFunc() + fs := "\033[1;31m%s\033[0m" if s == "on" { - color = fc.New(fc.FgGreen).SprintFunc() + fs = "\033[1;32m%s\033[0m" } - return color(s) + return fmt.Sprintf(fs, s) }