GNU bug report logs - #65358
30.0.50 [PATCH]; Add support for splicing Eshell globs in-place

Previous Next

Package: emacs;

Reported by: Jim Porter <jporterbugs <at> gmail.com>

Date: Thu, 17 Aug 2023 19:37:02 UTC

Severity: normal

Tags: patch

Found in version 30.0.50

Done: Jim Porter <jporterbugs <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Jim Porter <jporterbugs <at> gmail.com>
Subject: bug#65358: closed (Re: bug#65358: 30.0.50 [PATCH]; Add support
 for splicing Eshell globs in-place)
Date: Mon, 21 Aug 2023 18:48:01 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#65358: 30.0.50 [PATCH]; Add support for splicing Eshell globs in-place

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 65358 <at> debbugs.gnu.org.

-- 
65358: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=65358
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Jim Porter <jporterbugs <at> gmail.com>
To: 65358-done <at> debbugs.gnu.org
Subject: Re: bug#65358: 30.0.50 [PATCH]; Add support for splicing Eshell globs
 in-place
Date: Mon, 21 Aug 2023 11:47:00 -0700
On 8/17/2023 12:36 PM, Jim Porter wrote:
> With the attached patch, you can set 'eshell-glob-splice-results' to t 
> and then the above command will work as expected.

Merged to master as cf52cdb121b, and marking this done.

[Message part 3 (message/rfc822, inline)]
From: Jim Porter <jporterbugs <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 30.0.50 [PATCH]; Add support for splicing Eshell globs in-place
Date: Thu, 17 Aug 2023 12:36:05 -0700
[Message part 4 (text/plain, inline)]
One odd thing about Eshell is that when you expand a glob, it expands as 
a sublist within your argument list. In practice, that usually works out 
ok, since external commands (and some Eshell built-ins) will flatten the 
list of arguments before processing them.

However, this can cause issues when calling Lisp commands. For example, 
if I have a single patch file in my current directory, I might try to 
refer to it via "*.patch". This works fine for a command like "cat", but 
not for "find-file":

  ~ $ find-file *.patch
  Wrong type argument: stringp, 
("0001-Allow-splicing-Eshell-globs-in-place.patch")

With the attached patch, you can set 'eshell-glob-splice-results' to t 
and then the above command will work as expected.

I'm tempted to make this new behavior the default, since it smooths over 
the differences between Emacs Lisp functions and external commands in 
Eshell (when using the command form, that is). However, at least for 
now, I think it would be best to leave this off by default. Once any 
bugs have been worked out and people have had the chance to try it out, 
when we could consider changing the default one day.
[0001-Allow-splicing-Eshell-globs-in-place.patch (text/plain, attachment)]

This bug report was last modified 1 year and 332 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.