The open and composable observability and data visualization platform. Visualize metrics, logs, and traces from multiple sources like Prometheus, Loki, Elasticsearch, InfluxDB, Postgres and many more.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
grafana/pkg/cmd/grafana-cli/logger/logger.go

50 lines
664 B

package logger
import (
"fmt"
)
var (
debugmode = false
)
func Debug(args ...any) {
if debugmode {
fmt.Print(args...)
}
}
func Debugf(fmtString string, args ...any) {
if debugmode {
fmt.Printf(fmtString, args...)
}
}
func Error(args ...any) {
fmt.Print(args...)
}
func Errorf(fmtString string, args ...any) {
fmt.Printf(fmtString, args...)
}
func Info(args ...any) {
fmt.Print(args...)
}
func Infof(fmtString string, args ...any) {
fmt.Printf(fmtString, args...)
}
func Warn(args ...any) {
fmt.Print(args...)
}
func Warnf(fmtString string, args ...any) {
fmt.Printf(fmtString, args...)
}
func SetDebug(value bool) {
debugmode = value
}