News for hackers. Stuff that matters.
Re:Tell HN: Please don't print –help to stderr in your CLI t... by gwbas1c on Thursday September 28, 2023 @10:26AM (#37690060)
> 2>&1. You probably shouldn't be touching the shell if you don't know what that does...

I use the shell almost daily, and have shipped industry-leading products.

2>&1 is a vague memory because I'm not sure if I've ever done that; and I certainly shouldn't have to know some arcane shell trick to read the manual.

Re:Tell HN: Please don't print –help to stderr in your CLI t... by Hizonner on Thursday September 28, 2023 @11:22AM (#37690906)
It turns out that the right answer doesn't even depend on your level of shell knowledge or on how you tend to use the shell.

I use much more complicated pipe tricks than that interactively on a daily basis, and I definitely don't think of them as "arcane". As somebody who does that, it's useful to me to know which channel the data I want to pipe are going to come out on. Which is why help, which is normal requested output, should obviously go to stdout.

Usage messages issued in response to actual user errors are different, of course.

Re:Tell HN: Please don't print –help to stderr in your CLI t... by dingosity on Thursday September 28, 2023 @02:47PM (#37693906)
Sure. But the comment wasn't "You probably shouldn't be touching the shell if you haven't shipped industry-leading products" it was "You probably shouldn't be touching the shell if you don't know what that does."

Also, if you needed to use it every day, I suspect it would be more familiar than a vague memory.

Re:Tell HN: Please don't print –help to stderr in your CLI t... by gwbas1c on Friday September 29, 2023 @05:05PM (#37710071)
I use the shell almost daily.

I don't pipe command output daily, though. I use the shell because often it's easier than point-and-click for a lot of operations.

The shell has plenty of use cases that don't involve piping output. Saying you shouldn't touch the shell unless you understand piping output is like saying you shouldn't touch a refrigerator unless you know the perfect temperature to store milk.