[Gloucs] FAQ generation tool

Thomas Adam thomas at edulinux.homeunix.org
Fri Oct 1 21:29:24 BST 2004


On Fri, Oct 01, 2004 at 09:22:51PM +0100, Paul Broadhead wrote:
> Thomas Adam <thomas at edulinux.homeunix.org> wrote:
> > #! /usr/bin/bash env
> > # Generate FAQs from simple text files
> > 
> > That she-bang line is not standard.
> 
> Is there a standard one?  My usage comes from the kit I use at work.
> Some, non-Linux Unix machines which have bash installed in various
> places.

If that's the case, you're either not using Linux, or the sysadmin there needs
replacing. #!/usr/bin/bash env doesn't even make sense, let alone work. I
suspect what you really meant is:

!#/usr/bin/env bash

But this is completely superfluous, even if you did intend for it to be
written as such. If bash is not residing in /bin, then there is something
seriously wrong. Indeed, the magic(2) definitions for such listings dictate
and support this.

> > #!/bin/sh
> 
> But it's a bash script not sh!

The only difference in operation is initialisation of the subshell the script
will run in. Since /bin/sh is a symlink to /bin/bash on Linux system (and is
more portable), there is no difference here.

-- Thomas Adam

-- 
$ source ~/.bash_history




More information about the gloucs mailing list