From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8721 invoked by alias); 5 Feb 2010 15:50:53 -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: 27667 Received: (qmail 19081 invoked from network); 5 Feb 2010 15:50:48 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-3.0 required=5.0 tests=AWL,BAYES_00, RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=ham version=3.2.5 Received-SPF: none (ns1.primenet.com.au: domain at csr.com does not designate permitted sender hosts) Message-Id: <201002051549.o15Fn9lr024564@news01.csr.com> X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: zsh workers Subject: Re: extra arguments inserted by glob thinger e:: get sorted afterwards In-reply-to: <237967ef1002050715o3be2d441rcc8dbeb3e2b00483@mail.gmail.com> References: <237967ef1002050715o3be2d441rcc8dbeb3e2b00483@mail.gmail.com> Comments: In-reply-to Mikael Magnusson message dated "Fri, 05 Feb 2010 16:15:17 +0100." Date: Fri, 05 Feb 2010 15:49:08 +0000 From: Peter Stephenson X-OriginalArrivalTime: 05 Feb 2010 15:49:13.0216 (UTC) FILETIME=[C3A65800:01CAA67A] Content-Type: text/plain MIME-Version: 1.0 X-Scanned-By: MailControl A-09-22-10 (www.mailcontrol.com) on 10.68.0.115 Mikael Magnusson wrote: > Hi, someone just asked on irc how to give a globbed list of files to a > program with a -f inserted before each argument, so I told him > *(e:'reply=(-f $REPLY)':), that doesn't work however, as the arguments > are resorted afterwards, which seems like the less useful way to do > it. It's the *only* way to do it. The arguments are all assumed to be files, which is after all the point of globbing. Either you get them sorted as files or you don't get them sorted. -- Peter Stephenson Software Engineer Tel: +44 (0)1223 692070 Cambridge Silicon Radio Limited Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, UK Member of the CSR plc group of companies. CSR plc registered in England and Wales, registered number 4187346, registered office Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, United Kingdom