Does that mean that all commands that output the help info when an error is met do so to stderr, and never to stdout, even if -help is specifically called?
It is entirely up to the developer. Different developers have different views. If your command generates output which is likely to be redirected (i.e. most command line tools) then it makes sense to send the help text to stderr (that's MY view ).
It does make sense, but it means that output from commands with the --help option is treated differently depending on the command in question. To me this sounds like a bug in those commands that send the output to standard error.
With the --help option most binary applications (as for instance muungwana's zuluCrypt-cli
) send output to standard output. So do pinoc's
But some scripts, like mylivecd
, send it to standard error. And this is inconsistent. (So perhaps standard error and standard output need some semantic standardisation.)
Developers are notoriously lazy and would not write 2 different routines for --help and invalid parameter cases
You said it.
« Last Edit: January 02, 2013, 02:26:37 PM by Bald Brick »
Feed the trolls!
They need it!
AMD Athlon 7450 Dual-Core Processor, 7.80 GiB RAM, Nvidia GeForce GT 120/PCIe/SSE2, OpenGL/ES-version: 3.3 0 NVIDIA 295.40, SBx00 Azalia (Intel HDA) soundcard, Logitech B500 webcam, SAA7146 DVB card, HDDs: Seagate 250824AS, Western Digital WD10EAVS-00D