News for hackers. Stuff that matters.
Re:jc – JSONifies the output of many CLI tools by garfieldnate on Sunday November 06, 2022 @04:45AM (#33490840)
One of the features of Julia that I really like and wish would be adopted elsewhere is that the stringification methods take a context object that can indicate the string is to be presented in: plaintext, ansii-colored terminal, json, HTML, LaTeX, GraphViz, etc. It would have been amazing to have this kind of flexibility considered in the Unix tools.

That said, I would argue that JSONLines is a better universal output format when you're dealing with pipelines. If the output is one giant JSON array, then you have to wait for a long-running program to finish completely before the output can be passed on to the next long-running program. If you output one JSON line at a time as you process your input, then the next program in the pipeline can get started on processing already without waiting for the first to finish completely.

Re:jc – JSONifies the output of many CLI tools by kbrazil on Wednesday November 09, 2022 @12:37PM (#33535046)
Good news - `jc` supports JSONLines output for many commands and file-types, too!