service-tools/service-monitor/main.go

31 lines
573 B
Go
Raw Normal View History

2018-03-19 04:24:54 +08:00
package main
import (
"os"
"github.com/rivo/tview"
2018-03-19 04:24:54 +08:00
"github.com/spf13/cobra"
)
var (
RootCmd = &cobra.Command{
Use: "service-monitor",
Short: "service-monitor monitors systemd Units",
Long: "service-monitor is a convenient little tool to monitor systemd Units",
SilenceErrors: false,
SilenceUsage: true,
RunE: func(cmd *cobra.Command, args []string) error {
return logsCmd.RunE(cmd, args)
},
2018-03-19 04:24:54 +08:00
}
apperr error
app = tview.NewApplication()
2018-03-19 04:24:54 +08:00
)
func main() {
if err := RootCmd.Execute(); err != nil {
os.Exit(-1)
}
}