Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: lines to array
- X-seq: zsh-users 11196
- From: Meino Christian Cramer <Meino.Cramer@xxxxxx>
- To: pws@xxxxxxx
- Subject: Re: lines to array
- Date: Wed, 14 Feb 2007 18:09:01 +0100 (CET)
- Cc: zsh-users@xxxxxxxxxx
- In-reply-to: <200702141658.l1EGwp6R030740@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20070214112820.b115e849.pws@xxxxxxx> <20070214.175425.74743859.Meino.Cramer@xxxxxx> <200702141658.l1EGwp6R030740@xxxxxxxxxxxxxx>
From: Peter Stephenson <pws@xxxxxxx>
Subject: Re: lines to array
Date: Wed, 14 Feb 2007 16:58:51 +0000
Thanks Peter! :)
That helps me a lot!
mcc
> Meino Christian Cramer wrote:
> > One additional question: Is there a zshy way to sort
> > the array and throw away any doubled entry ?
>
> This is also documented:
>
> typeset -U array
> print ${(o)array}
>
> The -U flag applies when the array is set, the (o) flag when it
> is output. There's no way to specify that the array is always sorted;
> you have to assign
>
> array=(${(o)array})
>
> --
> Peter Stephenson <pws@xxxxxxx> Software Engineer
> CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
> Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070
>
>
> To access the latest news from CSR copy this link into a web browser: http://www.csr.com/email_sig.php
>
> To get further information regarding CSR, please visit our Investor Relations page at http://ir.csr.com/csr/about/overview
Messages sorted by:
Reverse Date,
Date,
Thread,
Author