signal/types: Use (min|max)Width in the column tag
@@ -22,10 +22,12 @@ import (
type Event struct {
eventtypes.Event
- Pid uint32 `json:"pid,omitempty" column:"pid,width:7,fixed"`
- Comm string `json:"comm,omitempty" column:"comm,width:16,fixed"`
- Signal string `json:"signal,omitempty" column:"signal,width:6,fixed,ellipsis:start"`
- TargetPid uint32 `json:"tpid,omitempty" column:"tpid,width:7,fixed"`
+ Pid uint32 `json:"pid,omitempty" column:"pid,minWidth:7"`
+ Comm string `json:"comm,omitempty" column:"comm,maxWidth:16"`
+ // The most common signals are SIGKILL, SIGTERM, SIGINT (6 chars) and the
+ // longest is SIGRTMIN+XX (11 chars).
+ Signal string `json:"signal,omitempty" column:"signal,minWidth:6,maxWidth:11,ellipsis:start"`
+ TargetPid uint32 `json:"tpid,omitempty" column:"tpid,minWidth:7"`
Retval int `json:"ret,omitempty" column:"ret,width:3,fixed"`
MountNsID uint64 `json:"mountnsid,omitempty" column:"mntns,width:12,hide"`
}
