Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:57525 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 25400 invoked from network); 26 Jan 2012 10:07:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 26 Jan 2012 10:07:13 -0000 Authentication-Results: pb1.pair.com smtp.mail=devis@oracolo.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=devis@oracolo.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain oracolo.com designates 209.85.215.42 as permitted sender) X-PHP-List-Original-Sender: devis@oracolo.com X-Host-Fingerprint: 209.85.215.42 mail-lpp01m010-f42.google.com Received: from [209.85.215.42] ([209.85.215.42:43846] helo=mail-lpp01m010-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 5A/42-10573-7C5212F4 for ; Thu, 26 Jan 2012 05:07:11 -0500 Received: by lahg1 with SMTP id g1so222164lah.29 for ; Thu, 26 Jan 2012 02:07:00 -0800 (PST) Received: by 10.112.8.168 with SMTP id s8mr347805lba.96.1327572420235; Thu, 26 Jan 2012 02:07:00 -0800 (PST) MIME-Version: 1.0 Sender: devis@oracolo.com Received: by 10.112.6.97 with HTTP; Thu, 26 Jan 2012 02:06:20 -0800 (PST) In-Reply-To: References: <4F20978D.2090605@gmail.com> <9570D903A3BECE4092E924C2985CE48539BC5EA4@MBX202.domain.local> Date: Thu, 26 Jan 2012 10:06:20 +0000 X-Google-Sender-Auth: fzGjac16HLxPRE3NSjnlJLRWja4 Message-ID: To: Ferenc Kovacs Cc: PHP internals Content-Type: multipart/alternative; boundary=e0cb4efe2bc085935704b76b8aee Subject: Re: [PHP-DEV] Shebang parsing From: devis@lucato.it --e0cb4efe2bc085935704b76b8aee Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi, from http://stackoverflow.com/questions/4303128/how-to-use-multiple-arguments-wi= th-a-shebang-i-e 1. Some operating systems simply treat the entire thing as the path. After all, in most operating systems, whitespace or dashes are legal in a path. 2. Some operating systems split at whitespace and treat the first part as the path to the interpreter and the rest as individual arguments. 3. Some operating systems split at the *first* whitespace and treat the front part as the path to the interpeter and the rest as= a *single* argument (which is what you are seeing). 4. Some even don't support shebang lines *at all*. Thankfully, 1. and 4. seem to have died out, but 3. is pretty widespread, so you simply cannot rely on being able to pass more than one argument. Devis 2012/1/26 Ferenc Kovacs > it has a length limit, if I remember correctly it is some reall short val= ue > on linux. > it seems to be 127 character: > http://www.in-ulm.de/~mascheck/various/shebang/ > > 2012/1/26 Clint M Priest > > > I've never gotten -d in shebang to work properly, I'd love to see that > > working. > > > > > -- > Ferenc Kov=C3=A1cs > @Tyr43l - http://tyrael.hu > --e0cb4efe2bc085935704b76b8aee--