summaryrefslogtreecommitdiffstats
path: root/dependencies/pkg/mod/github.com/mattn/go-colorable@v0.1.13/_example/logrus/main.go
blob: c569164b2e2b074d1ff2eeef0aa07d7c5186bf18 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
package main

import (
	"github.com/mattn/go-colorable"
	"github.com/sirupsen/logrus"
)

func main() {
	logrus.SetFormatter(&logrus.TextFormatter{ForceColors: true})
	logrus.SetOutput(colorable.NewColorableStdout())

	logrus.Info("succeeded")
	logrus.Warn("not correct")
	logrus.Error("something error")
	logrus.Fatal("panic")
}