Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: A question about filename generate
- X-seq: zsh-users 30330
- From: Perry Smith <pedz@xxxxxxxxxxxxxxxx>
- To: Marc Chantreux <mc@xxxxxxxxxx>
- Cc: safreya <safreya@xxxxxx>, zsh-users@xxxxxxx
- Subject: Re: A question about filename generate
- Date: Sun, 27 Jul 2025 07:23:22 -0500
- Arc-authentication-results: i=1; rspamd-696f8998d-nq456; auth=pass smtp.auth=a2hosting smtp.mailfrom=pedz@xxxxxxxxxxxxxxxx
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1753619016; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=Z993K4D5RSHDWgzbYiKaTlHHQTSU4bLMwGUvJJyFBeg=; b=0jvNa6ZYGlXeezqsQUnoTHtFEFRlzBeBMKfOdAJKpV5CXwoPtf34C4NjEpLVLd/O2XaXlx BvTnex471AxLAeYxs+PRb5I5pnw0zL5h5e2K6g2WqQXcqAW9CtiFEQaAWBn/Tom3nQqiWr WvS2FHak1/BeJEZRJKWsRQn+GKw+gToU6mGslP0JlnKemgZmhX7O2np7q9tTBlRqikV7qP qigpQU19yRcN5x01YPr3S2364NZ2nmTx5r8/W+QreR0chOxpTHr0rHUzB1ofe8yd6I9Nwf t/kOSby9jCswWN5aUt2+buhq1IC1Y+1OswGMEcQFyn9LdXQM7QMDCEPYtibsDA==
- Arc-seal: i=1; s=arc-2022; d=mailchannels.net; t=1753619016; a=rsa-sha256; cv=none; b=kJp64UpDfg8pAsgls+zym27Q1hj2pW4N7h7zL44+hKGj/hGdgdJwvHeHTsNSq8RXc3q3eN F2UhlGCYcTAuinhJ0eOoHWC4+dXbCtwpz45sBG5nSwk7EipXyAT3fR59Pp/Bl4WWBJ5mkJ qTaieIupl2dWVff85W8npByOKEYYSGzrQuOFXVNoinHGEn3+m2Jz7PEPQ/gef82SzmBBFN +S7zzWPh617drUpRjB35TDIbq7r6Z8t6NbInb6XLvv8U4tD7sS44p/nWj6++/DpiUUlUio zrXBSjAxxXr6rO1uojND2/mpxRxEhcwH7mGYXHbo8JvklfRdKxEwh4B8LEdaNA==
- Archived-at: <https://zsh.org/users/30330>
- In-reply-to: <aIXEhg9QG9uRxn0X@prometheus>
- List-id: <zsh-users.zsh.org>
- References: <tencent_69AD6695B9D82E219704D6455D01C5D08A05@qq.com> <aIXEhg9QG9uRxn0X@prometheus>
> On Jul 27, 2025, at 01:17, Marc Chantreux <mc@xxxxxxxxxx> wrote:
>
> hello,
>
> # when you can, please provide a way for people who want to help
> # a simple why to setup sandbox
>
> mkdir subdir
> touch subdir/file{a..c}.{tex,aux}
> touch index.{tex,aux,log}
>
> # prefered version because its result is streamed so you can
> # process things on fly:
>
> find . \! -name '*.tex' -type f
>
> # zsh glob version: retention of all the result to build the
> # print arguments list.
>
> print -l **~*.tex(.)
>
> regards
Sorry… I’m confused.
The find yields:
find . \! -name '*.tex' -type f
./subdir/filec.aux
./subdir/fileb.aux
./subdir/filea.aux
./index.log
./index.aux
The print yields:
print -l **~*.tex(.)
index.aux
index.log
What did I do wrong?
I think what you want is:
print -l **/*~*.tex(.)
index.aux
index.log
subdir/filea.aux
subdir/fileb.aux
subdir/filec.aux
But I’m still confused (surprised) why OPs original pattern did what it did.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author