[SLL] script interpreter bootstrap tricks

Brian Hatch bri at ifokr.org
Tue Apr 1 13:04:30 PDT 2008


Pretty near to 2008-04-01 11:49 -0700, Ted Stern uttered:

> Everyone knows that you start a vanilla Bourne shell script with a
> shebang:
> 
>          #!/bin/sh
> 
> But what do you do if you want to interpret the script with some tool,
> like perl, python, tclsh or even bash, that is either not installed in
> /bin or is not listed in /etc/shells?  And it may not be located in
> the default path, so "#!/usr/bin/env <utility>" won't work.


Sometimes there are too many problems you're working around, and need
to fix the problem.

Is adding the directory to your path s.t. #!/usr/bin/env really
not an acceptable solution?

-- 
Brian Hatch                  The opinions expressed in
   Systems and                this email are mine, however
   Security Engineer          I may not agree with them.
http://www.ifokr.org/bri/

Every message PGP signed
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists2.linuxjournal.com/pipermail/linux-list/attachments/20080401/1df9d3cf/attachment.sig 


More information about the linux-list mailing list