Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: recurse up
- X-seq: zsh-users 13079
- From: "Mikael Magnusson" <mikachu@xxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: recurse up
- Date: Thu, 31 Jul 2008 21:56:03 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=SaN5ujxREkHVoX/BW6gGDerNtbX6fGqryPy0OmG4gb0=; b=pdJTVOqQw/MdAv2XTLNOig8HrXH4CuVPGunCYkIbCgsYYln6P1zH6b22Bax6Z7roEP pK/PSk2i0FYsvtbDRXYS16Kdv6ttJ4KTq4ysJqEkJInEsXOStKR28U0HEQ8V/PzH7UKm xXpz6xNTLAkOtTGG8U0jj03YBPNagSWWsuxQI=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=xwjx0k8FM6D1/zXftcdpUcVs4imX7OfCgWl4JM1UK8OKuCZSlYGCnjnrMwqJ1cTWt5 I0woiXQ/JUbOPkECFqXziLzaf7dInk1uDA1dbQUcW/IXXX9ImcUF7ub6MUA7rGmJtcES uRmrLut+PdHuddxdfxjIqa+Aq6JnfI3wjul28=
- In-reply-to: <20080731195050.GA4092@xxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20080731195050.GA4092@xxxxxxxxxxxxxxx>
2008/7/31 Anthony Fletcher <arif@xxxxxxxxxxxxxxx>:
> One can find files that live below the current directory via
>
> ls **/README
>
> but how can one look for files in the parent, grand-parent, ...
> directories?
>
> For example, suppose that the file /a/README exists and the current
> directory is /a/b/c/d/e. Then, I'd like
>
> ls .../README
>
> to glob expand to ../../../README.
>
> Any suggestions?
The man page says:
As a shorthand, `**/' is equivalent to `(*/)#'; note that this
therefore matches
files in the current directory as well as subdirectories.
So you can use (../)#README
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author