From 8324ccf75567c736592fd121ad5353a7dbdacbad Mon Sep 17 00:00:00 2001 From: "Yury G. Kudryashov" Date: Thu, 15 Apr 2010 15:47:15 +0000 Subject: [PATCH] Add /var/run/current-system/sw to NIX_PROFILES Also adds a possibility to just add KDE packages to systemPackages. svn path=/nixos/trunk/; revision=21103 --- modules/programs/bash/bashrc.sh | 9 +++++---- .../services/x11/desktop-managers/kde-environment.nix | 9 +++------ 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/modules/programs/bash/bashrc.sh b/modules/programs/bash/bashrc.sh index f12b95637b41..8f5a417bcc20 100644 --- a/modules/programs/bash/bashrc.sh +++ b/modules/programs/bash/bashrc.sh @@ -3,7 +3,6 @@ if [ -n "$NOSYSBASHRC" ]; then fi # Initialise a bunch of environment variables. -export PATH=/var/run/current-system/sw/bin:/var/run/current-system/sw/sbin export LD_LIBRARY_PATH=/var/run/opengl-driver/lib export MODULE_DIR=@modulesTree@/lib/modules export NIXPKGS_CONFIG=/nix/etc/config.nix @@ -11,14 +10,15 @@ export NIXPKGS_ALL=/etc/nixos/nixpkgs export PAGER="less -R" export EDITOR=nano export LOCATE_PATH=/var/cache/locatedb -export GST_PLUGIN_PATH=/var/run/current-system/sw/lib/gstreamer-0.10 -@shellInit@ # Include the various profiles in the appropriate environment variables. NIX_USER_PROFILE_DIR=/nix/var/nix/profiles/per-user/$USER -NIX_PROFILES="/nix/var/nix/profiles/default $NIX_USER_PROFILE_DIR/profile" +NIX_PROFILES="/var/run/current-system/sw /nix/var/nix/profiles/default $NIX_USER_PROFILE_DIR/profile" + +unset PATH INFOPATH PKG_CONFIG_PATH PERL5LIB GST_PLUGIN_PATH KDEDIRS +unset XDG_CONFIG_DIRS XDG_DATA_DIRS for i in $NIX_PROFILES; do # !!! reverse export PATH=$i/bin:$i/sbin:$PATH @@ -37,6 +37,7 @@ for i in $NIX_PROFILES; do # !!! reverse export XDG_CONFIG_DIRS=$i/etc/xdg:$XDG_CONFIG_DIRS export XDG_DATA_DIRS=$i/share:$XDG_DATA_DIRS done +@shellInit@ # Search directory for Aspell dictionaries. diff --git a/modules/services/x11/desktop-managers/kde-environment.nix b/modules/services/x11/desktop-managers/kde-environment.nix index 98b92e42b851..19f092b07061 100644 --- a/modules/services/x11/desktop-managers/kde-environment.nix +++ b/modules/services/x11/desktop-managers/kde-environment.nix @@ -15,6 +15,8 @@ let description = '' Additional KDE packages to be used when you use KDE as a desktop manager. By default, you only get the KDE base packages. + Just adds packages to systemPackages and x11Packages. Will be removed + in the future. ''; }; @@ -27,11 +29,6 @@ mkIf (kdePackages != [] && config.services.xserver.enable) { environment = { x11Packages = kdePackages; - - shellInit = '' - export KDEDIRS="${pkgs.lib.concatStringsSep ":" kdePackages}" - export XDG_CONFIG_DIRS="${pkgs.lib.makeSearchPath "etc/xdg" kdePackages}" - export XDG_DATA_DIRS="${pkgs.lib.makeSearchPath "share" kdePackages}" - ''; + systemPackages = kdePackages; }; }