Skip to content
Snippets Groups Projects
Unverified Commit 7c0754eb authored by Daniel Nelson's avatar Daniel Nelson
Browse files

Move usage string to internal to fix `go run`

parent 757e23a5
No related branches found
No related tags found
No related merge requests found
...@@ -13,6 +13,7 @@ import ( ...@@ -13,6 +13,7 @@ import (
"syscall" "syscall"
"github.com/influxdata/telegraf/agent" "github.com/influxdata/telegraf/agent"
"github.com/influxdata/telegraf/internal"
"github.com/influxdata/telegraf/internal/config" "github.com/influxdata/telegraf/internal/config"
"github.com/influxdata/telegraf/logger" "github.com/influxdata/telegraf/logger"
_ "github.com/influxdata/telegraf/plugins/aggregators/all" _ "github.com/influxdata/telegraf/plugins/aggregators/all"
...@@ -192,7 +193,7 @@ func reloadLoop( ...@@ -192,7 +193,7 @@ func reloadLoop(
} }
func usageExit(rc int) { func usageExit(rc int) {
fmt.Println(usage) fmt.Println(internal.Usage)
os.Exit(rc) os.Exit(rc)
} }
......
// +build !windows // +build !windows
package main package internal
const usage = `Telegraf, The plugin-driven server agent for collecting and reporting metrics. const Usage = `Telegraf, The plugin-driven server agent for collecting and reporting metrics.
Usage: Usage:
......
// +build windows // +build windows
package main package internal
const usage = `Telegraf, The plugin-driven server agent for collecting and reporting metrics. const Usage = `Telegraf, The plugin-driven server agent for collecting and reporting metrics.
Usage: Usage:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment