Path: utzoo!mnetor!uunet!lll-winken!lll-lcc!ames!ll-xn!mit-eddie!PREP.AI.MIT.EDU!mly From: mly@PREP.AI.MIT.EDU (Richard Mlynarik) Newsgroups: comp.emacs Subject: environment-hacking in Emacs Message-ID: <8802291942.AA16482@prep.ai.mit.edu> Date: 29 Feb 88 19:42:14 GMT Sender: daemon@eddie.MIT.EDU Reply-To: mly-prep@prep.ai.mit.edu Lines: 23 Path: mit-eddie!bloom-beacon!mgm.mit.edu!wolfgang From: wolfgang@MGM.MIT.EDU (Wolfgang Rupprecht) Newsgroups: comp.emacs Subject: Re: Mail drop path for mode line Date: 29 Feb 88 05:05:16 GMT Sender: daemon@BLOOM-BEACON.MIT.EDU You can change an emacs-childs environment variables via redefining the emacs variable process-environment. Here is some code for changing (sub)shell variables from GnuEmacs. (Note current emacs variable that (getenv "FOO") returns will not be updated.) [...] Even better, if you compile emacs with the -DMAINTAIN_ENVIRONMENT compilation flag (set in in config.h), you will have full getenv/setenv-style control over the environment used not only by Emacs' subprocesses, but that used by Emacs itself (such as in $... filename expansion). [Why this switch is not turned on by default in Emacs is something I have never understood and am tired of fighting for.]