forked from mirrors/statsd_exporter
Print version, help etc to stdout
The default behavior of kingpin lib is to print stuff to stderr. This is now changed by using the os.Stdout writer. Now information like version and help text will be printed to stdout. Signed-off-by: don-philipe <don_philipe@gmx.de>
This commit is contained in:
parent
aecad1a2fa
commit
00d82daaf2
1 changed files with 1 additions and 0 deletions
1
main.go
1
main.go
|
@ -265,6 +265,7 @@ func main() {
|
|||
promlogConfig := &promlog.Config{}
|
||||
flag.AddFlags(kingpin.CommandLine, promlogConfig)
|
||||
kingpin.Version(version.Print("statsd_exporter"))
|
||||
kingpin.CommandLine.UsageWriter(os.Stdout)
|
||||
kingpin.HelpFlag.Short('h')
|
||||
kingpin.Parse()
|
||||
logger := promlog.New(promlogConfig)
|
||||
|
|
Loading…
Reference in a new issue