GNU bug report logs -
#68074
eshell sudo/doas does not work for aliases
Previous Next
Full log
Message #33 received at 68074-done <at> debbugs.gnu.org (full text, mbox):
On 1/27/2024 12:46 AM, Alfonso Sanchez-Beato via Bug reports for GNU
Emacs, the Swiss army knife of text editors wrote:
>
> En sábado, 27 de enero de 2024, 01:19:32 GMT, Jim Porter <jporterbugs <at> gmail.com> escribió:
>> ... actually, this is a more-complete patch. I'm not 100% sure about
>> this part though:
>>
>> ',(car args)
>>
>> That (usually) creates something like (quote "command"), but it's safer
I thought about this some more and the extraneous quoting is fine in my
opinion. Eshell already does that quite a bit in 'eshell-do-eval', so
what's one more case?
> This last patch works nicely, thanks a lot! It works also in cases where my patch was not, like:
>
> $ eshell/sudo VAR=val <alias> ...
Wait, that works?! (After trying it out locally, so it does!)
Looking at the code, I see why now: 'eshell-named-command' calls
'eshell-prepare-command-hook', and that hook is where we handle local
variables. However, I truly didn't expect that; I thought the local
variable handling occurred in an earlier phase. The more you know...
Anyway, since this works even better than I'd expected, I've now merged
my patch to the master branch as 3c680968e49. Closing this bug now.
This bug report was last modified 1 year and 115 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.