jqnatividad / qsv

CSVs sliced, diced & analyzed.
https://qsv.dathere.com
The Unlicense
2.43k stars 70 forks source link

move --help from stderr to stout #2105

Closed ondohotola closed 3 days ago

ondohotola commented 1 week ago

If I run --help I have to add 2>&1 before I can pipe it through less which I don't have to do for --list.

I often forget and then have to quit less, repeat the command, with the redirection.

jqnatividad commented 1 week ago

This requires tweaking docopt a bit.

Added it to the backlog @ondohotola .

ondohotola commented 1 week ago

Thanks.

jqnatividad commented 4 days ago

To confirm, looking at GNU guidelines...

https://www.gnu.org/prep/standards/standards.html#g_t_002d_002dhelp

It does specify that --help and --version should both go to stdout, not stderr.

jqnatividad commented 4 days ago

Moved qsv_docopt crate to https://github.com/dathere/qsv-docopt.

Fixes will be done there going forward.

@rzmk, also will implement the enhancement there so qsv pro can show usage text. Thinking of using markdown on all usage text so it looks prettier on qsv pro...

rzmk commented 4 days ago

If switching to markdown for the usage text then it may be neat to render it as formatted in the terminal too:

jqnatividad commented 3 days ago

termimad looks awesome @rzmk!

Apart from styling, it handles scrolling too!