From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: (qmail 4848 invoked from network); 19 Apr 2020 00:03:14 -0000 Received-SPF: pass (primenet.com.au: domain of zsh.org designates 203.24.36.2 as permitted sender) receiver=inbox.vuxu.org; client-ip=203.24.36.2 envelope-from= Received: from ns1.primenet.com.au (HELO primenet.com.au) (203.24.36.2) by inbox.vuxu.org with UTF8ESMTPZ; 19 Apr 2020 00:03:14 -0000 Received: (qmail 27158 invoked by alias); 19 Apr 2020 00:03:08 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: List-Unsubscribe: X-Seq: 24798 Received: (qmail 2695 invoked by uid 1010); 19 Apr 2020 00:03:08 -0000 X-Qmail-Scanner-Diagnostics: from mail-ot1-f43.google.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.102.2/25779. spamassassin: 3.4.4. Clear:RC:0(209.85.210.43):SA:0(-1.9/5.0):. Processed in 2.618593 secs); 19 Apr 2020 00:03:08 -0000 X-Envelope-From: schaefer@brasslantern.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _netblocks.google.com designates 209.85.210.43 as permitted sender) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=U10UvNNuv/h3yc2NN+HnBie9tTTg5fmg/H2O4kX54UI=; b=AdfB+6JI0GpC89CZEHU2PtVEKhC4BC/OU1nF8WD3gpy+y7h1Ia41UofO4Yu3G2lyIw uTRE/8nLMe2QHVcjz01k9qtZILQbjZ6TB2G5vY8EHMSEY2+Vvl8O8dNKNK/a+loIHg3M dCmg/atT3Qp/PpnMbOepF+dSLo/6pJR/eTme+XUolHrvREOGcNsdBiDj8ktEXMBt1fAF cggwq6zvkEygtaD84hTPZ1+SfbeN7Aowj0EaOdZIdmqaBFY4y3st8qhzHeVQ0QDcDpU9 M9eb6Xj8LD9W4tU8o2VGZZIhkddvmg2EdXQpWDi6Cgy2tZ+C6a/Mey2JLE2UI9+/8kTf AALA== X-Gm-Message-State: AGi0PubdJXxsnSKMzEdXcmtajgnwE3hDP4o7U4g1uoNGDPmgtiKm8kRY E0o0xp6GfMi2ivOuNo7F8PmJKbYl7qxC/on201PFhw== X-Google-Smtp-Source: APiQypK48i/JQzP9tL0nrZXJK5OoEgxauYPvvVK/62wlz8NlvDHEfZL4NjJx5kqixTISnBhT4nBlpr2ty6CSXPDwk2k= X-Received: by 2002:a9d:72c2:: with SMTP id d2mr4706270otk.260.1587254551498; Sat, 18 Apr 2020 17:02:31 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Bart Schaefer Date: Sat, 18 Apr 2020 17:02:20 -0700 Message-ID: Subject: =?UTF-8?B?UmU6IEhvdyB0byBvdmVyY29tZSB0aGUgKGEvYi9j4oCmKShOKSBwYXR0ZXJuIGxpbWl0YQ==?= =?UTF-8?B?dGlvbj8=?= To: Sebastian Gniazdowski Cc: Zsh Users Content-Type: text/plain; charset="UTF-8" On Sat, Apr 18, 2020 at 4:24 PM Sebastian Gniazdowski wrote: > > On Sat, 18 Apr 2020 at 22:00, Bart Schaefer wrote: >> >> In this case, "useful" collides directly with "practical" given the >> semantics of "/" imposed by the underlying file system. > > What do you mean? I mean that given a directory tree a/b/c/d/e/f, you can't do opendir("a/b/c") and then get back "d/e/f" from readdir(), whereas every other pattern can be compared directly against a value returned by readdir(). > it puzzled me that such /-using patterns aren't allowed. Mikachu has a patch allowing them, maybe it's worth adding it to the upstream?: > > http://comm.it.cx/cgit/zsh-cvs/commit/?h=mika&id=512bd3f23ea8b4170d88582521d417cdb247413a I don't think that actually does what you want. This works: % setopt jankypatterns % ls -d (Completion/Base/Core|Completion/X/Type) Completion/Base/Core Completion/X/Type But this doesn't: % ls -d */(Base/Core|X/Type) zsh: bad pattern: */(Base/Core|X/Type) % ls -d (*/(Base/Core|X/Type)) zsh: no matches found: (*/(Base/Core|X/Type)) The latter failures are why Mikachu's patch is not presently suitable for inclusion upstream.