[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#295328: general: Help messages to stderr should be banned



ti, 2005-02-15 kello 10:19 +0100, Marco d'Itri kirjoitti:
> On Feb 15, Justin Pryzby <justinpryzby@users.sf.net> wrote:
> 
> > I suppose I will start filing minor bugs against packages that do
> > this.  I'd like to hear other people's opinions, though.  (It occurs
> > to me that help output to stderr is arguably appropriate if an invalid
> > option is given).  Part of the problem is that its fairly depressing
> WTF? This is a long-time UNIX tradition, I'd summarily close such a bug
> opened on one of my packages.

In my opinion, if you give a wrong option (or do some other syntax error
on the command line), the proper thing to do is to give an error
message, preferably short, saying what the error was and how to get the
full help text. This is an error message, so it should go to the
standard error output. 

When the user explicitly requests for a help text, it is not an error
and should go to the standard output.

GNU tools work like this already, and have, to the best of my knowledge,
worked like this for well over a decade. Tools that behave differently
are also fairly common, so I guess tradition isn't clearcut here.

I do claim that the GNU way is the right way here.



Reply to: