mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
pkg/cmd: Check errors (#19700)
* pkg/cmd: Check errors * pkg/cmd: Make sure server waits on services, even in case of error * pkg/cmd: Inform of error to show help * pkg/cmd: Only warn on failure to send systemd notification * pkg/cmd: Don't log errors stemming from context cancelation * pkg/cmd: Don't fail if unable to write to systemd
This commit is contained in:
@@ -7,7 +7,7 @@ import (
|
||||
)
|
||||
|
||||
type CommandLine interface {
|
||||
ShowHelp()
|
||||
ShowHelp() error
|
||||
ShowVersion()
|
||||
Application() *cli.App
|
||||
Args() cli.Args
|
||||
@@ -35,8 +35,8 @@ type ContextCommandLine struct {
|
||||
*cli.Context
|
||||
}
|
||||
|
||||
func (c *ContextCommandLine) ShowHelp() {
|
||||
cli.ShowCommandHelp(c.Context, c.Command.Name)
|
||||
func (c *ContextCommandLine) ShowHelp() error {
|
||||
return cli.ShowCommandHelp(c.Context, c.Command.Name)
|
||||
}
|
||||
|
||||
func (c *ContextCommandLine) ShowVersion() {
|
||||
|
||||
Reference in New Issue
Block a user