Initial commit

This commit is contained in:
Mikaël Cluseau
2018-06-12 20:52:20 +11:00
commit 1293dd0444
13 changed files with 1157 additions and 0 deletions

33
log/taint.go Normal file
View File

@ -0,0 +1,33 @@
package log
import (
"novit.nc/direktil/src/pkg/color"
)
const (
Normal Taint = iota
Info
Warning
Error
Fatal
OK
)
type Taint byte
func (t Taint) Color() color.Color {
switch t {
case Info:
return color.Blue
case Warning:
return color.Yellow
case Error:
return color.Red
case Fatal:
return color.Magenta
case OK:
return color.Green
default:
return color.None
}
}