diff options
author | Shea Levy <shea@shealevy.com> | 2017-03-25 11:13:25 -0400 |
---|---|---|
committer | Shea Levy <shea@shealevy.com> | 2017-03-25 11:13:25 -0400 |
commit | f087b7594150998652f6b7945b0ca86bceba9e79 (patch) | |
tree | 2c0ed7be58c940670d1119b272431fabf5c2b91e /pkgs/build-support/emacs | |
parent | 55d21cad95cf325e42c0919d1ed8a290d9207f4d (diff) | |
download | nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.tar nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.tar.gz nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.tar.bz2 nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.tar.lz nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.tar.xz nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.tar.zst nixpkgs-f087b7594150998652f6b7945b0ca86bceba9e79.zip |
nix-buffer support: Make process-environment changes actually local
Diffstat (limited to 'pkgs/build-support/emacs')
-rw-r--r-- | pkgs/build-support/emacs/buffer.nix | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pkgs/build-support/emacs/buffer.nix b/pkgs/build-support/emacs/buffer.nix index 1cbac0709a6..6c5e0570fd0 100644 --- a/pkgs/build-support/emacs/buffer.nix +++ b/pkgs/build-support/emacs/buffer.nix @@ -39,6 +39,8 @@ (make-local-variable 'process-environment) (put 'process-environment 'permanent-local t) (inherit-local 'process-environment) + ; setenv modifies in place, so copy the environment first + (setq process-environment (copy-tree process-environment)) (setenv "PATH" (concat "${lib.makeSearchPath "bin" pkgs}:" (getenv "PATH"))) (inherit-local-permanent exec-path (append '(${builtins.concatStringsSep " " (map (p: "\"${p}/bin\"") pkgs)}) exec-path)) |