From 8eca4db54aed5b0969a2f0c56e2736cb3c8a078a Mon Sep 17 00:00:00 2001 From: Peter Simons Date: Sat, 31 Dec 2011 12:56:45 +0000 Subject: [PATCH] /etc/profile: do not add ~/bin to $PATH in system-wide init file Users who want a user-specific bin directory to override system paths should configure that in their user-specific ~/.bashrc, not in the system-wide init file. The global file shouldn't add directories from user homes to $PATH without knowing whether those actually exist or whether the users even want them in $PATH. On my system, for example, there is no ~/bin, so I don't want my $PATH to look for one. Removing an erroneous entry from $PATH is cumbersome, but adding one is easy, so it feels better to err on the side of caution. svn path=/nixos/trunk/; revision=31188 --- modules/programs/bash/profile.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/programs/bash/profile.sh b/modules/programs/bash/profile.sh index 07be87ffd7d..91f6007c0fe 100644 --- a/modules/programs/bash/profile.sh +++ b/modules/programs/bash/profile.sh @@ -59,8 +59,8 @@ done # Search directory for Aspell dictionaries. export ASPELL_CONF="dict-dir $HOME/.nix-profile/lib/aspell" -# ~/bin and the setuid wrappers override other bin directories. -export PATH=$HOME/bin:@wrapperDir@:$PATH +# The setuid wrappers override other bin directories. +export PATH=@wrapperDir@:$PATH # Set up the per-user profile. mkdir -m 0755 -p $NIX_USER_PROFILE_DIR