News for hackers. Stuff that matters.
Re:Coreutils Gotchas (2015) by tssva on Friday June 18, 2021 @02:32PM (#27553388)
The context of the article is the Gnu coreutils. The coreutils version of echo accepts options which is not allowed according to the link you referenced. Therefore within the context of the article stating echo is non-portable is correct.
Re:Coreutils Gotchas (2015) by uplime on Friday June 18, 2021 @02:53PM (#27553602)
GNU coreutils isn't a standard. It conforms to and extends the POSIX standard. If it was just talking about GNU echo, then that `echo` would work the same on every machine. It even explicitly mentions other `echo` implementations, like the shell builtins. `echo` itself is portable, none of its flags are.
Re:Coreutils Gotchas (2015) by burntsushi on Friday June 18, 2021 @03:59PM (#27554311)
You seem to have a very narrow definition of "portable." Can you link to the definition of the jargon term you appear to be using here?

Also, have you considered that some words have colloquial meanings too, and that it doesn't make sense to label them as "not correct"?

Re:Coreutils Gotchas (2015) by uplime on Friday June 18, 2021 @05:31PM (#27555260)
> You seem to have a very narrow definition of "portable."

Can you explain how wanting to include more programs into the definition of portable is narrow?

> Can you link to the definition of the jargon term you appear to be using here?

The same definition I've always seen in every community discussing shell-scripting: if it's specified by the POSIX (Portable Operating System Interface) standard. POSIX does have a definition of `echo`. GNU echo does not conform to it by default, but can be configured to.

> Also, have you considered that some words have colloquial meanings too, and that it doesn't make sense to label them as "not correct"?

But it makes sense to label `echo` itself as not portable? The argument can be made that `GNU echo` is not portable (even though it can be with an environment variable), however that should be specified, instead of mentioning there are several implementations where it is non-standard.

Re:Coreutils Gotchas (2015) by burntsushi on Friday June 18, 2021 @06:13PM (#27555567)
You sound like a zealot to be honest. You misconstrued my post and gave a disingenuous response IMO. And you didn't answer my questions.