Skip to content

Commit

Permalink
feat: logger
Browse files Browse the repository at this point in the history
  • Loading branch information
SantiiRepair committed Dec 19, 2023
1 parent 9af0e0b commit 48818d1
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions kreacher/logger.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package kreacher

import (
"log"
"log/syslog"
)

func NewLogger() *log.Logger {
var logger *log.Logger

syslogWriter, err := syslog.New(syslog.LOG_INFO, "my-app")
if err != nil {
log.Fatal(err)
}
logger.SetOutput(syslogWriter)
logger.SetFlags(0)

return logger
}
File renamed without changes.

0 comments on commit 48818d1

Please sign in to comment.