mirror of
https://github.com/elyby/chrly.git
synced 2024-12-23 21:50:03 +05:30
Логгер в консоль теперь не добавляет метку в конец строки, а также выводит время в более коротком формате
This commit is contained in:
parent
8007b082d6
commit
ac714de8df
@ -8,8 +8,8 @@ import (
|
|||||||
"github.com/assembla/cony"
|
"github.com/assembla/cony"
|
||||||
"github.com/getsentry/raven-go"
|
"github.com/getsentry/raven-go"
|
||||||
"github.com/mono83/slf/rays"
|
"github.com/mono83/slf/rays"
|
||||||
"github.com/mono83/slf/recievers/ansi"
|
|
||||||
"github.com/mono83/slf/recievers/statsd"
|
"github.com/mono83/slf/recievers/statsd"
|
||||||
|
"github.com/mono83/slf/recievers/writer"
|
||||||
"github.com/mono83/slf/wd"
|
"github.com/mono83/slf/wd"
|
||||||
|
|
||||||
"elyby/minecraft-skinsystem/logger/receivers/sentry"
|
"elyby/minecraft-skinsystem/logger/receivers/sentry"
|
||||||
@ -22,7 +22,10 @@ func GetVersion() string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func CreateLogger(statsdAddr string, sentryAddr string) (wd.Watchdog, error) {
|
func CreateLogger(statsdAddr string, sentryAddr string) (wd.Watchdog, error) {
|
||||||
wd.AddReceiver(ansi.New(true, true, false))
|
wd.AddReceiver(writer.New(writer.Options{
|
||||||
|
Marker: false,
|
||||||
|
TimeFormat: "15:04:05.000",
|
||||||
|
}))
|
||||||
if statsdAddr != "" {
|
if statsdAddr != "" {
|
||||||
hostname, _ := os.Hostname()
|
hostname, _ := os.Hostname()
|
||||||
statsdReceiver, err := statsd.NewReceiver(statsd.Config{
|
statsdReceiver, err := statsd.NewReceiver(statsd.Config{
|
||||||
|
Loading…
Reference in New Issue
Block a user