This is the mail archive of the
cygwin@sources.redhat.com
mailing list for the Cygwin project.
Re: [OT] #!/usr/bin/env bash -vx
- To: Josifovski Ljubomir-BLJ01Z <BLJ01Z at motorola dot com>
- Subject: Re: [OT] #!/usr/bin/env bash -vx
- From: Mumit Khan <khan at NanoTech dot Wisc dot EDU>
- Date: Wed, 31 Jan 2001 11:17:56 -0600 (CST)
- cc: "Cygwin Mailing List (E-mail)" <cygwin at sourceware dot cygnus dot com>
On Wed, 31 Jan 2001, Josifovski Ljubomir-BLJ01Z wrote:
>
> This is not exclusive to cygwin, but maybe someone here can help me. I put
>
> #!/usr/bin/env bash
>
> in the first line on some scripts I use on Cygwin, Linux and HP-UX because
> the exact path to bash differs (someone posted this trick on the list
> sometime ago). But when arguments are added to the line, like
>
> #!/usr/bin/env bash -vx
>
> this doesn't work anymore - I get:
It's the way env works, especially in conjunction with '#!'. If you
really want to do this, create a wrapper script, where you can define
all the flags. In this example, the interpreter Cygwin or Linux or any
other OS will call up is "bash -vx", which is it not a valid interpreter
name ("bash" by itself is of course).
Regards,
Mumit
--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple