emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Buffer-local process environments


From: Arthur Miller
Subject: Re: [PATCH] Buffer-local process environments
Date: Sat, 28 Aug 2021 18:43:59 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Augusto Stoffel <arstoffel@gmail.com> writes:

>> Now you make me confused again :). I want my process to use different env for
>> LANG and LC_TIME, but Emacs should continue to work with old values. 
>> Concretely
>> I want english date string, but my Emacs should continue to use swedish for 
>> it's
>> normal use.
>>
>> So if I let-bind, it will be reflected only localy in that let scope, and the
>> subprocess will inherit that local environment too? That is what I want, and 
>> why
>> I went via shell command. Forgive me if I am confused. I hope what you said
>> above is what I want :-).
>
>
> If it's a one-off thing, you can always do
>
>     (let ((process-environment (cons "LANG=en" process-environemnt)))
>       (process-launching-stuff))
>
> Now, suppose you want to automate this within a certain project.  Then
> you want to arrange for
>
>     (setq-local process-environment (cons "LANG=en" process-environemnt))
>
> to be called in every buffer of the project (there are packages out
> there to help doing this).  This mostly works, but some commands get
> confused when `process-environment' has a buffer-local value.  The patch
> is a fix for `compile'.

Yes, yes. Thanks both. I guess I can switch to call-process now with let-bind 
:).



reply via email to

[Prev in Thread] Current Thread [Next in Thread]