From 24b6c463ab744d1029fc92ed0adaf49db1761083 Mon Sep 17 00:00:00 2001 From: Didip Kerabat Date: Fri, 18 Jul 2014 15:47:34 -0700 Subject: [PATCH] Update frontpage README --- README.md | 3 +++ hooks/syslog/README.md | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 41e23ef..fb98376 100644 --- a/README.md +++ b/README.md @@ -148,12 +148,15 @@ Logrus comes with built-in hooks. Add those, or your custom hook, in `init`: ```go import ( + "log/syslog" "github.com/Sirupsen/logrus" "github.com/Sirupsen/logrus/hooks/airbrake" + "github.com/Sirupsen/logrus/hooks/syslog" ) func init() { log.Hooks.Add(new(logrus_airbrake.AirbrakeHook)) + log.Hooks.Add(logrus_syslog.NewSyslogHook("udp", "localhost:514", syslog.LOG_INFO, "")) } ``` diff --git a/hooks/syslog/README.md b/hooks/syslog/README.md index 74dc73f..cd706bc 100644 --- a/hooks/syslog/README.md +++ b/hooks/syslog/README.md @@ -11,7 +11,7 @@ import ( func main() { log := logrus.New() - hook, err := NewSyslogHook("udp", "localhost:514", syslog.LOG_INFO, "") + hook, err := logrus_syslog.NewSyslogHook("udp", "localhost:514", syslog.LOG_INFO, "") if err == nil { log.Hooks.Add(hook)