diff --git a/os/glog/glog_config.go b/os/glog/glog_config.go index 6e4402dee..173913d73 100644 --- a/os/glog/glog_config.go +++ b/os/glog/glog_config.go @@ -153,3 +153,8 @@ func GetLevelPrefix(level int) string { func SetHandlers(handlers ...Handler) { logger.SetHandlers(handlers...) } + +//SetWriterColorEnable sets the file logging with color +func SetWriterColorEnable(enabled bool) { + logger.SetWriterColorEnable(enabled) +} diff --git a/os/glog/glog_logger_config.go b/os/glog/glog_logger_config.go index 6cc95ef05..20dec0cd3 100644 --- a/os/glog/glog_logger_config.go +++ b/os/glog/glog_logger_config.go @@ -249,3 +249,8 @@ func (l *Logger) SetPrefix(prefix string) { func (l *Logger) SetHandlers(handlers ...Handler) { l.config.Handlers = handlers } + +//SetWriterColorEnable sets the file logging with color +func (l *Logger) SetWriterColorEnable(enabled bool) { + l.config.WriterColorEnable = enabled +}