util-linux/tests/expected/lsblk
Karel Zak 94dbb32273 libsmartcols: cleanup and extend padding functionality
LIBSMARTCOLS_DEBUG_PADDING=on in the next examples forces libsmartcols
print '.' as a padding char. See line "ffff" in the exmaples.

* default output is to fill all except last cell

	$ LIBSMARTCOLS_DEBUG_PADDING=on ./sample-scols-fromfile --nlines 10  --width 80 --column tests/ts/libsmartcols/files/col-name --column tests/ts/libsmartcols/files/col-number --column tests/ts/libsmartcols/files/col-string --column tests/ts/libsmartcols/files/col-string tests/ts/libsmartcols/files/data-string tests/ts/libsmartcols/files/data-number tests/ts/libsmartcols/files/data-string-empty tests/ts/libsmartcols/files/data-string-empty 2> /dev/null
	NAME.. ......NUM STRINGS STRINGS
	aaaa.. ........0 aaaa... aaaa
	bbb... ......100 bbb.... bbb
	ccccc. .......21 ccccc.. ccccc
	dddddd ........3 dddddd. dddddd
	ee.... ......411 ee..... ee
	ffff.. .....5111 .......
	gggggg 678993321 gggggg. gggggg
	hhh... ..7666666 hhh.... hhh

* scols_table_enable_minout() minimizes output for tailing empty cells, example:

	$ LIBSMARTCOLS_DEBUG_PADDING=on ./sample-scols-fromfile --nlines 10 --minout  --width 80 --column tests/ts/libsmartcols/files/col-name --column tests/ts/libsmartcols/files/col-number --column tests/ts/libsmartcols/files/col-string --column tests/ts/libsmartcols/files/col-string tests/ts/libsmartcols/files/data-string tests/ts/libsmartcols/files/data-number tests/ts/libsmartcols/files/data-string-empty tests/ts/libsmartcols/files/data-string-empty 2> /dev/null
	NAME.. ......NUM STRINGS STRINGS
	aaaa.. ........0 aaaa... aaaa
	bbb... ......100 bbb.... bbb
	ccccc. .......21 ccccc.. ccccc
	dddddd ........3 dddddd. dddddd
	ee.... ......411 ee..... ee
	ffff.. .....5111
	gggggg 678993321 gggggg. gggggg
	hhh... ..7666666 hhh.... hhh

* cleanup up scols_table_enable_maxout() use, example:

	$ LIBSMARTCOLS_DEBUG_PADDING=on ./sample-scols-fromfile --nlines 10 --maxout  --width 80 --column tests/ts/libsmartcols/files/col-name --column tests/ts/libsmartcols/files/col-number --column tests/ts/libsmartcols/files/col-string --column tests/ts/libsmartcols/files/col-string tests/ts/libsmartcols/files/data-string tests/ts/libsmartcols/files/data-number tests/ts/libsmartcols/files/data-string-empty tests/ts/libsmartcols/files/data-string-empty 2> /dev/null
	NAME.............. ..................NUM STRINGS............ STRINGS............
	aaaa.............. ....................0 aaaa............... aaaa...............
	bbb............... ..................100 bbb................ bbb................
	ccccc............. ...................21 ccccc.............. ccccc..............
	dddddd............ ....................3 dddddd............. dddddd.............
	ee................ ..................411 ee................. ee.................
	ffff.............. .................5111 ................... ...................
	gggggg............ ............678993321 gggggg............. gggggg.............
	hhh............... ..............7666666 hhh................ hhh................

Note that we cannot make scols_table_enable_minout() default because
for example "column --table" is pretty commonly used with non-blank
columns separator and in this case all cells has to be filled.

	$ echo -e "aa,b,ccc\na,,\naaa,bbb,ccc" |  column --table --separator ',' --output-separator '|'
	aa |b  |ccc
	a  |   |
	aaa|bbb|ccc

Addresses: https://github.com/karelzak/util-linux/issues/826
Signed-off-by: Karel Zak <kzak@redhat.com>
2019-07-23 16:24:42 +02:00
..
lsblk-simple-lvm-basic tests: add simple LVM lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-lvm-discard tests: add simple LVM lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-lvm-rw tests: add simple LVM lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-lvm-state tests: add simple LVM lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-lvm-topo tests: add simple LVM lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-lvm-vendor libsmartcols: cleanup and extend padding functionality 2019-07-23 16:24:42 +02:00
lsblk-simple-lvm-zone tests: add simple LVM lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-nvme-basic tests: add simple ATA and NVME lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-nvme-discard tests: add simple ATA and NVME lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-nvme-rw tests: add simple ATA and NVME lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-nvme-state tests: add simple ATA and NVME lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-nvme-topo tests: add simple ATA and NVME lsblk dump 2018-06-21 13:19:28 +02:00
lsblk-simple-nvme-vendor libsmartcols: cleanup and extend padding functionality 2019-07-23 16:24:42 +02:00
lsblk-simple-nvme-zone tests: add simple ATA and NVME lsblk dump 2018-06-21 13:19:28 +02:00