From 3471bc1d082643234eee676b15ef79f06e50389d Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Wed, 12 Oct 2022 09:43:17 +0200 Subject: [PATCH] lsblk: improve mountpoint columns formatting Let's mark the columns by no-extreme libsmartcols flag. It makes output more compact if there are too long mount paths. Signed-off-by: Karel Zak --- misc-utils/lsblk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/misc-utils/lsblk.c b/misc-utils/lsblk.c index 655463e418..ea06afcd10 100644 --- a/misc-utils/lsblk.c +++ b/misc-utils/lsblk.c @@ -221,8 +221,8 @@ static struct colinfo infos[] = { [COL_START] = { "START", 5, SCOLS_FL_RIGHT, N_("partition start offset"), COLTYPE_NUM }, [COL_STATE] = { "STATE", 7, SCOLS_FL_TRUNC, N_("state of the device") }, [COL_SUBSYS] = { "SUBSYSTEMS", 0.1, SCOLS_FL_NOEXTREMES, N_("de-duplicated chain of subsystems") }, - [COL_TARGETS] = { "MOUNTPOINTS", 0.10, SCOLS_FL_WRAP, N_("all locations where device is mounted") }, - [COL_TARGET] = { "MOUNTPOINT", 0.10, SCOLS_FL_TRUNC, N_("where the device is mounted") }, + [COL_TARGETS] = { "MOUNTPOINTS", 0.10, SCOLS_FL_WRAP | SCOLS_FL_NOEXTREMES, N_("all locations where device is mounted") }, + [COL_TARGET] = { "MOUNTPOINT", 0.10, SCOLS_FL_TRUNC | SCOLS_FL_NOEXTREMES, N_("where the device is mounted") }, [COL_TRANSPORT] = { "TRAN", 6, 0, N_("device transport type") }, [COL_TYPE] = { "TYPE", 4, 0, N_("device type") }, [COL_UUID] = { "UUID", 36, 0, N_("filesystem UUID") }, -- 2.47.3