good morning!!!!

Skip to content
Snippets Groups Projects
Commit c6e2af14 authored by Péter Szilágyi's avatar Péter Szilágyi
Browse files

cmd/geth: limit the maximum chart colums to 6

parent 3ea6b5ae
No related branches found
No related tags found
No related merge requests found
......@@ -85,7 +85,9 @@ func monitor(ctx *cli.Context) {
utils.Fatalf("No metrics specified.\n\nAvailable:\n - %s", strings.Join(list, "\n - "))
}
sort.Strings(monitored)
if cols := len(monitored) / ctx.Int(monitorCommandRowsFlag.Name); cols > 6 {
utils.Fatalf("Requested metrics (%d) spans more that 6 columns:\n - %s", len(monitored), strings.Join(monitored, "\n - "))
}
// Create and configure the chart UI defaults
if err := termui.Init(); err != nil {
utils.Fatalf("Unable to initialize terminal UI: %v", err)
......
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