[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#56227: 29.0.50; Eshell globs ending with '/' should match directorie
From: |
Jim Porter |
Subject: |
bug#56227: 29.0.50; Eshell globs ending with '/' should match directories only |
Date: |
Sat, 25 Jun 2022 18:52:57 -0700 |
On 6/25/2022 6:45 PM, Jim Porter wrote:
For consistency with other shells, and to make Eshell's globbing more
expressive, I think we should make the latter match directories only.
While this technically changes an existing behavior, it should be a safe
change to make, since there's currently no reason I'm aware of to add a
trailing slash to an Eshell glob.
Here's the patch. The first part refactors em-glob.el a bit, and
converts globs into regexps ahead of time. This is partly to make the
second patch simpler, but also improves performance by a few percent
when `eshell-glob-entries' examines many directories: it no longer
repeatedly converts the same glob component for each sibling directory.
The second part is the actual patch for this bug.
0001-Convert-Eshell-globs-ahead-of-time-instead-of-doing-.patch
Description: Text document
0002-Make-Eshell-globs-ending-in-match-directories-only.patch
Description: Text document