column
linux
Format `stdin` or a file into multiple columns. Columns are filled before rows; the default separator is a whitespace.
More info →Options (4)
-c, --output-widthbooleanFormat the output of a command for a 30 characters wide display
Example:
printf "header1 header2\nbar foo\n" | column {{[-c|--output-width]}} {{30}}-t, --tablebooleanSplit columns automatically and auto-align them in a tabular format
Example:
printf "header1 header2\nbar foo\n" | column {{[-t|--table]}}-s, --separatorbooleanSpecify the column delimiter character for the `--table` option (e.g. "," for CSV) (defaults to whitespace)
Example:
printf "header1,header2\nbar,foo\n" | column {{[-t|--table]}} {{[-s|--separator]}} {{,}}-x, --fillrowsbooleanFill rows before filling columns
Example:
printf "header1\nbar\nfoobar\n" | column {{[-c|--output-width]}} {{30}} {{[-x|--fillrows]}}Examples (4)
Format the output of a command for a 30 characters wide display
Split columns automatically and auto-align them in a tabular format
Specify the column delimiter character for the `--table` option (e.g. "," for CSV) (defaults to whitespace)
made by @shridhargupta | data from tldr-pages