forked from vieter-v/vieter
feat(console): tabled outputs now optionally return without decorations
This commit is contained in:
parent
cf67b46df0
commit
8a08788935
4 changed files with 34 additions and 10 deletions
|
|
@ -5,6 +5,11 @@ import strings
|
|||
import cli
|
||||
import os
|
||||
|
||||
// tabbed_table returns a simple textual table, with tabs as separators.
|
||||
pub fn tabbed_table(data [][]string) string {
|
||||
return data.map(it.join('\t')).join('\n')
|
||||
}
|
||||
|
||||
// pretty_table converts a list of string data into a pretty table. Many thanks
|
||||
// to @hungrybluedev in the Vlang Discord for providing this code!
|
||||
// https://ptb.discord.com/channels/592103645835821068/592106336838352923/970278787143045192
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue