Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: path and += troubles
- X-seq: zsh-users 9708
- From: Christian Taylor <cht@xxxxxxxxx>
- To: "zsh-users" <zsh-users@xxxxxxxxxx>
- Subject: Re: path and += troubles
- Date: Sat, 26 Nov 2005 10:32:35 +0100
- In-reply-to: <2FDFACEA-C7A6-4F45-897D-B786CC632463@xxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <2FDFACEA-C7A6-4F45-897D-B786CC632463@xxxxxxxxxxxxxxx>
Steven Klass wrote:
> Hi all,
>
> OK after reading the FAQ completely I am at my wits end. I want to
> create three basic functions dealing with arrays
> - Append
> - Prepend
> - Delete
I don't know if this is exactly what you're looking for, but I think you can
save yourself some work by just using direct operations.
Prepending/Appending:
path=( prepended $path appended )
I never bothered about a deletion function, because I simply use:
typeset -U path
which will keep only the first occurence of any element.
Hope this is of some help,
Christian
Messages sorted by:
Reverse Date,
Date,
Thread,
Author