aboutsummaryrefslogtreecommitdiffhomepage
path: root/print.go
diff options
context:
space:
mode:
Diffstat (limited to 'print.go')
-rw-r--r--print.go18
1 files changed, 7 insertions, 11 deletions
diff --git a/print.go b/print.go
index 7c6663bd..891c576b 100644
--- a/print.go
+++ b/print.go
@@ -247,22 +247,18 @@ func printPs(output io.Writer, now time.Time, s state.Store, short, flagJSON boo
t := newPrinter(output)
defer t.MustFlush()
- t.Println("\tInstance\tPID\tApp\tUptime\tEnablements\tCommand")
+ t.Println("\tInstance\tPID\tApplication\tUptime")
for _, e := range exp {
- var (
- es = "(No confinement information)"
- cs = "(No command information)"
- as = "(No configuration information)"
- )
+ as := "(No configuration information)"
if e.Config != nil {
- es = e.Config.Confinement.Enablements.String()
- cs = fmt.Sprintf("%q", e.Config.Args)
as = strconv.Itoa(e.Config.Confinement.AppID)
+ if e.Config.ID != "" {
+ as += " (" + e.Config.ID + ")"
+ }
}
- t.Printf("\t%s\t%d\t%s\t%s\t%s\t%s\n",
- e.s[:8], e.PID, as, now.Sub(e.Time).Round(time.Second).String(), strings.TrimPrefix(es, ", "), cs)
+ t.Printf("\t%s\t%d\t%s\t%s\n",
+ e.s[:8], e.PID, as, now.Sub(e.Time).Round(time.Second).String())
}
- t.Println()
}
type expandedStateEntry struct {