Possible bug in SunOS System V echo?
Doug Gwyn
gwyn at smoke.BRL.MIL
Wed May 2 16:01:45 AEST 1990
In article <14020094 at hpisod2.HP.COM> decot at hpisod2.HP.COM (Dave Decot) writes:
-> One would think that 1003.2 would get this
-> straightened out, but as a practical matter we need more than just a
-> final standard spec for "echo", we also need a viable transition plan.
-A viable transition plan has been decided and published in POSIX.2 Draft 9.
-Of course, the uses of echo that were always portable remain so:
- echo Hello world!
-However, in the POSIX environment, thou shalt not depend on non-portable
-behavior. Thou shalt not use "echo" with an -n option, and thou shalt
-not use any sequences such as "\c", "\n", or "\b" in its arguments. Use
-of either causes unspecified output.
-If thou requirest special processing beyond simply echoing printing
-characters followed by a newline, thou shalt use the "printf" utility:
- printf "Hi there!\n\nEnter your name: "
Well, that's dumb. Now I have to support TWO commands, where one would do.
What sort of standardization is this?
More information about the Comp.unix.wizards
mailing list