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

Re: Proposed new POSIX sh policy, version two

Mike Hommey <mh@glandium.org> writes:

> On Sat, Nov 25, 2006 at 09:51:37AM +0200, Jari Aalto <jari.aalto@cante.net> wrote:
> > And this is only possible if scripts use
> > 
> >     /bin/sh
> > 
> > The  /bin/sh could be any valid shell that provided the standard set
> > of features. 
> > 
> > The installation system ("Essential") which sets /bin/sh to point to
> > /bin/bash in this respect has been a bad choice because people are not
> > aware of the bashinm they might be using as a result of it.
> Maybe bash should restrict its features when called sh... like gzip
> changes its features when called gunzip, etc.

I think this would complicate the bash's C-code base unnecessarily.
The problem is not in the bash, but in the symlink. The proper way
would be to ship in etch+1

    /bin/sh -> /bin/dash

And leave bash as it is now (in essential and for interactive use; as
a default shell). Breaking the symlink to bash of course would need
decision from the board that is resposible for such a change.

In practise the change will not be that big at all, because as
demonstrated, the Debian works fine and with no breakage if the
symlink points to dash[1]. It's good to know that developers pay
attention to lintian bashism warnings and the maintainer scripts are
in fact mostly "bash free".

[1] I can of course speak from perspective other than "testing" brach
where I have been running such systems for 1-2 years. The selected
packages however do not represent the whole set of packages, so there
is no doubt still bashim somewhere. But on the whole, all seem to work
nicely and I wouldn't expecte the transition to move to dash have big

Reply to: