Re: [RFC] war on echo in scripts
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- Jul 9, 2010, 14:10 UTC
- Message-ID
- <20100709141011.GA1543@burratino>
- In-Reply-To
- <AANLkTint6AfhwKdeizt-YVt4O6AZbLG9A5h6ipJyQyIQ@mail.gmail.com>
Ævar Arnfjörð Bjarmason wrote:
> (Via H.Merijn Brand): This fails on the old HP-UX 10.20 bourne shell:
Git commands require a Posix-style shell (with support for $() among other things), which I suspect would rule out shells like the one you’re talking about. Still, portability is something to worry about...
Show 15 quoted lines
> > cat xx.sh
> #!/bin/sh
>
> echo ()
> {
> perl -le'print "Done!"'
> }
>
> echo 1
> echo Klaar
> > sh xx.sh
> xx.sh[3]: The operation is not allowed in a restricted shell.:
> echo is a shell builtin.
> 1
> KlaarThat’s weird. Where did “restricted shell” come into it?
Thanks for the example, Jonathan