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

Re: [PATCH] latest ash has broken 'echo' command



> On Fri, Oct 22, 1999 at 04:20:25PM +0200, Filip Van Raemdonck wrote:
> 
> > > we have a policy that requires #!/bin/sh scripts to be POSIX compliant so
> > > that this can happen.  Problem is that we've got too many scripts which
> > > just aren't compliant
> > 
> > But the fact that scripts aren't compliant does not mean that the shell
> > should break them even more,
> 
> Well the fact is that if ash has to support features that are not required
> by POSIX (but are compatible with it), just where do you draw the line? Many
> bashisms belong to this category.  Pretty soon ash will become bash.

"Be liberal in what you accept, be conservative in what you generate".

In the case of standards like POSIX /bin/sh, I think this general rule 
of thumb means that implementations should try to support all the 
common optional features, if possible, AND that /bin/sh scripts should 
try to avoid using any optional features.

This does not lead to a slippery slope of bashisms...  If POSIX says X, 
optionally Y, it would be reasonable to do X+Y without tending towards 
bash.  Doing X+Y+Z would not be reasonable, unless there was a -very- 
good reason.

In any event...

  Is "echo" specified as part of the shell according to POSIX, or is 
ash going beyond the call of POSIX in supporting "echo" at all?  If ash 
is implementing "echo" for convenience, speed over /bin/echo, not 
because of a POSIX requirement, then shouldn't it's behavior match that 
of the existing /bin/echo is is supposedly "conveniently" replacing?


> -- 
> Debian GNU/Linux 2.1 is out! ( http://www.debian.org/ )
> Email:  Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
> Home Page: http://gondor.apana.org.au/~herbert/
> PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
> 
> 
> -- 
> To UNSUBSCRIBE, email to debian-devel-request@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
> 
> 

-- 
     Buddha Buck                      bmbuck@zaphod.dhis.edu
"Just as the strength of the Internet is chaos, so the strength of our
liberty depends upon the chaos and cacophony of the unfettered speech
the First Amendment protects."  -- A.L.A. v. U.S. Dept. of Justice



Reply to: