Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: extra arguments inserted by glob thinger e:: get sorted afterwards
- X-seq: zsh-workers 27688
- From: JÃrg Sommer <joerg@xxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: extra arguments inserted by glob thinger e:: get sorted afterwards
- Date: Mon, 8 Feb 2010 10:08:06 +0000 (UTC)
- Dkim-signature: v=1; a=rsa-sha256; c=simple/simple; d=gnuu.de; s=banki; t=1265630670; i=@xxxxxxxxxxxx; bh=OONQE9QIwPNNLAX7i+GNvKFmMX+fSYk7g GCbV0xMJeY=; h=To:From:Subject:Date:Message-ID:References: Mime-Version:Content-Type:Content-Transfer-Encoding:Sender; b=JXuy RuWzWfN7atraCePyaINpayUXhxj1XGzCP6HQsd2pljQN30wJNK08RQybZpyObflINQE 45tUzgJUFKRCltch6CVebQj7pZ6WfemMIl21J9H9stYfqyo/Wu01c+Fabgqz10EiNYT 4Py6qJtZmRCHAMtanep+WxIACqkaFYO9Y=
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <237967ef1002050715o3be2d441rcc8dbeb3e2b00483@xxxxxxxxxxxxxx>
- Sender: news <news@xxxxxxxxxxxx>
Hello Mikael,
Mikael Magnusson <mikachu@xxxxxxxxx> 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. Of course one can add oN, but it would be nicer if you could both
> sort files and add extra arguments. Stuff like oa doesn't make sense
> on the inserted arguments anyway.
>
> % print -- *.sh(oNe:'reply=(-f $REPLY)':)
> -f zmpc.sh -f ifs.sh -f test.sh -f script_pandora.sh
Why not use $^?
% print -- -f\ ${(f)^"$(print -l /bin/ls*)"}
-f /bin/ls -f /bin/lsmod
Bye, JÃrg.
--
> Definiere âDemokratieâ â
â eine Mehrheit beweist einer Minderheit, dass Widerstand zwecklos ist.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author