Zsh Mailing List Archive
Messages sorted by:
Re: (-) doesn't make (e) working on the files which symbolic links point to ?
- X-seq: zsh-users 19280
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: (-) doesn't make (e) working on the files which symbolic links point to ?
- Date: Fri, 24 Oct 2014 09:05:23 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=nSWdS6if9K5AQETx/mhWwD1h7+t/PlDbwvqDL7vJqgk=; b=HWv3V/uh2v+JAMn2KEke/DmS/P7j0aEheF0aTQ/2uNy9DTNCq769XHDUq4QVZM6yod 4Xy3KUXi/N381FcwK+LDKxfyULnZur9q9jkYlk7PQGdFDGOEujEDaI3rwSYUcJ+SgGeT 8Gx3OfqZurarzPJlOQAn34pWk1TnanEj2OYNxD7XluQhjBnuLQ+pxZ0VCVEiLGS8HDvN eaqY4xV82bv1c6Aco17GI1p/eODs53yV9CpAXEVn4/umeYKn80GHqSTQK9d6lYqm1KBS Y43yFNHQQVS2uCVhdLqWHr0pt9oKAz+iW64IehE6bt5YNJ5QnOV3NSLLEpJ/tpUe6W+J VhWA==
- In-reply-to: <20141024062838.GB3496@localhost.localdomain>
- List-help: <mailto:email@example.com>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:firstname.lastname@example.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <20141024021406.GA3496@localhost.localdomain> <141023202253.ZM19726@torch.brasslantern.com> <20141024062838.GB3496@localhost.localdomain>
On Fri, Oct 24, 2014 at 8:28 AM, Han Pingtian <hanpt@xxxxxxxxxxxxxxxxxx> wrote:
> On Thu, Oct 23, 2014 at 08:22:53PM -0700, Bart Schaefer wrote:
>> On Oct 24, 10:14am, Han Pingtian wrote:
>> } Looks like the qualifer "(-)" doesn't make "(e)" works on files pointed
>> } by symblic
>> The only thing that (-) controls is whether the file attributes are read
>> by lstat() or stat(). It does not cause a readlink(); note that even in
>> the absence of (e), the names returned by *(@-) are the names of the links
>> and not of the files linked-to.
>> You want (:A) like so:
>> ls -l /dev/disk/by-id/*(:Ae'.[[ $REPLY = *sda* ]].')
> I'm sorry, it doesn't work. The outputs of "*(:Ae'.[[ $REPLY = *sda* ]].')"
> is the same as "*(:A)".
It would appear that :A causes the e to not execute at all, but in
either case the end result would not be the desired one. The following
works, if your zsh is new enough to allow globbing in this context.
ls -l /dev/disk/by-id/*(e.'[[ $REPLY(#q:A) = *sda* ]]'.)
Messages sorted by: