mirror of
https://github.com/bloeys/nmage.git
synced 2025-12-29 05:18:21 +00:00
Uniforms and better logging
This commit is contained in:
19
logging/logging.go
Executable file
19
logging/logging.go
Executable file
@ -0,0 +1,19 @@
|
||||
package logging
|
||||
|
||||
import (
|
||||
"log"
|
||||
"os"
|
||||
)
|
||||
|
||||
var (
|
||||
InfoLog *log.Logger
|
||||
WarnLog *log.Logger
|
||||
ErrLog *log.Logger
|
||||
)
|
||||
|
||||
func init() {
|
||||
|
||||
InfoLog = log.New(os.Stdout, "INFO: ", log.Ldate|log.Ltime|log.Lshortfile)
|
||||
WarnLog = log.New(os.Stdout, "WARN: ", log.Ldate|log.Ltime|log.Lshortfile)
|
||||
ErrLog = log.New(os.Stderr, "Err: ", log.Ldate|log.Ltime|log.Lshortfile)
|
||||
}
|
||||
Reference in New Issue
Block a user