From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3604 invoked by alias); 25 Jan 2011 17:33:33 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 28651 Received: (qmail 11941 invoked from network); 25 Jan 2011 17:33:30 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,T_TO_NO_BRKTS_FREEMAIL autolearn=ham version=3.3.1 Received-SPF: none (ns1.primenet.com.au: domain at free.fr does not designate permitted sender hosts) Content-Type: text/plain; charset=iso-8859-1 Mime-Version: 1.0 (Apple Message framework v1082) Subject: Re: Bang Executing Perl Scripts From: =?iso-8859-1?Q?Fran=E7ois_Revol?= In-Reply-To: Date: Tue, 25 Jan 2011 15:42:20 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <7CD7FAD1-563E-4FC9-AB38-E5FC94887946@free.fr> References: <1246B8BF-933E-4143-9B06-62197CE64B94__21660.9615985819$1295907908$gmane$org@free.fr> To: zsh-workers@zsh.org X-Mailer: Apple Mail (2.1082) Le 25 janv. 2011 =E0 12:42, Klaus Ethgen a =E9crit : > Moin, >=20 > Fran=E7ois Revol schrieb: >>> Why not putting #!/usr/bin/perl as the first line of your perl = scripts? >>=20 >> This is not portable. >=20 > Portable enough today. But if you want to support minor OSs like BeOS = or > windows ... I wouldn't call BeOS "minor". It might have had a limited diffusion, but = it did introduce to the desktop OSes many concepts people now claim that = they invented, like tickless, node monitoring... "BeOS did it 15y ago" At least you didn't mention Haiku in the list :) As for Windows, its audience is certainly not minor, despite not having = the favors of real hackers (except as a target for study). :) >> BeOS and Haiku do not have /usr for ex, so perl is elsewhere. >> (and so is env, so using #!/usr/bin/env perl is just moving the = problem around) >=20 > ... look at =BBperldoc perlrun=AB: > #!/bin/sh > #! -*-perl-*- > eval 'exec perl -x -wS $0 ${1+"$@"}' > if 0; >=20 > There is a pretty good change that /bin/sh is available on relevant > systems. But also for this solution, you cannot support all exotic > systems. Indeed, this would probably work in BeOS in Haiku. But I agree it looks = overkill. Fran=E7ois.=