about summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2014-06-13 18:33:58 +0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2014-06-13 18:34:56 +0200
commit13befa3979d6ac98a96880fba9a3239bc333e644 (patch)
tree9745c08a73c25faa114b4f22fbda0c5db68f165e /nixos/modules
parentf5055e2ef6cbb7e836ba80d8458647555aae6793 (diff)
downloadnixlib-13befa3979d6ac98a96880fba9a3239bc333e644.tar
nixlib-13befa3979d6ac98a96880fba9a3239bc333e644.tar.gz
nixlib-13befa3979d6ac98a96880fba9a3239bc333e644.tar.bz2
nixlib-13befa3979d6ac98a96880fba9a3239bc333e644.tar.lz
nixlib-13befa3979d6ac98a96880fba9a3239bc333e644.tar.xz
nixlib-13befa3979d6ac98a96880fba9a3239bc333e644.tar.zst
nixlib-13befa3979d6ac98a96880fba9a3239bc333e644.zip
Set session variables in the shell as well
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/config/shells-environment.nix6
1 files changed, 6 insertions, 0 deletions
diff --git a/nixos/modules/config/shells-environment.nix b/nixos/modules/config/shells-environment.nix
index e3ddf9e3c5fa..cc079cdc5856 100644
--- a/nixos/modules/config/shells-environment.nix
+++ b/nixos/modules/config/shells-environment.nix
@@ -149,6 +149,12 @@ in
 
     system.build.binsh = pkgs.bashInteractive;
 
+    # Set session variables in the shell as well. This is usually
+    # unnecessary, but it allows changes to session variables to take
+    # effect without restarting the session (e.g. by opening a new
+    # terminal instead of logging out of X11).
+    environment.variables = config.environment.sessionVariables;
+
     environment.etc."shells".text =
       ''
         ${concatStringsSep "\n" cfg.shells}