]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
misc: clenaup SIZE columns in lsblk and findmnt
authorKarel Zak <kzak@redhat.com>
Tue, 20 Mar 2012 10:04:48 +0000 (11:04 +0100)
committerKarel Zak <kzak@redhat.com>
Tue, 20 Mar 2012 10:04:48 +0000 (11:04 +0100)
Note that lib/tt.c will never truncate columns without TT_FL_TRUNC or
relative column width. So it's fine to set small width for columns
with SIZEs, the defined width is minimal width.

Signed-off-by: Karel Zak <kzak@redhat.com>
misc-utils/findmnt.c
misc-utils/lsblk.c

index 9ac7c460c893d44b4c6e40df5be62ba661716d41..476263c27c7510e513171ff3f0b87c6d6f86cc8b 100644 (file)
@@ -107,10 +107,10 @@ static struct colinfo infos[FINDMNT_NCOLUMNS] = {
        [COL_ACTION]       = { "ACTION",         10, TT_FL_STRICTWIDTH, N_("action detected by --poll") },
        [COL_OLD_OPTIONS]  = { "OLD-OPTIONS",  0.10, TT_FL_TRUNC, N_("old mount options saved by --poll") },
        [COL_OLD_TARGET]   = { "OLD-TARGET",   0.30, 0, N_("old mountpoint saved by --poll") },
-       [COL_SIZE]         = { "SIZE",            8, TT_FL_RIGHT, N_("filesystem size") },
-       [COL_AVAIL]        = { "AVAIL",           8, TT_FL_RIGHT, N_("filesystem size available") },
-       [COL_USED]         = { "USED",            8, TT_FL_RIGHT, N_("filesystem size used") },
-       [COL_USEPERC]      = { "USE%",            8, TT_FL_RIGHT, N_("filesystem use percentage") },
+       [COL_SIZE]         = { "SIZE",            5, TT_FL_RIGHT, N_("filesystem size") },
+       [COL_AVAIL]        = { "AVAIL",           5, TT_FL_RIGHT, N_("filesystem size available") },
+       [COL_USED]         = { "USED",            5, TT_FL_RIGHT, N_("filesystem size used") },
+       [COL_USEPERC]      = { "USE%",            3, TT_FL_RIGHT, N_("filesystem use percentage") },
 };
 
 /* global flags */
index 9c0be27493c9e125689b509505698251a0ffe957..4ff0102db690073dcb1105754d2ed6ec39bec0e8 100644 (file)
@@ -112,7 +112,7 @@ static struct colinfo infos[] = {
        [COL_RM]     = { "RM",      1, TT_FL_RIGHT, N_("removable device") },
        [COL_ROTA]   = { "ROTA",    1, TT_FL_RIGHT, N_("rotational device") },
        [COL_MODEL]  = { "MODEL",   0.1, TT_FL_TRUNC, N_("device identifier") },
-       [COL_SIZE]   = { "SIZE",    6, TT_FL_RIGHT, N_("size of the device") },
+       [COL_SIZE]   = { "SIZE",    5, TT_FL_RIGHT, N_("size of the device") },
        [COL_STATE]  = { "STATE",   7, TT_FL_TRUNC, N_("state of the device") },
        [COL_OWNER]  = { "OWNER",   0.1, TT_FL_TRUNC, N_("user name"), },
        [COL_GROUP]  = { "GROUP",   0.1, TT_FL_TRUNC, N_("group name") },