From fc7a2c50fcd0608d8fd50cbde442e7c296c2632c Mon Sep 17 00:00:00 2001 From: "Wayne E. Seguin" Date: Fri, 25 Mar 2011 01:15:32 -0400 Subject: [PATCH] Ensure etc_profile_file is assigned. --- scripts/functions/installer | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/functions/installer b/scripts/functions/installer index 7fc09c220f..5196a7f363 100644 --- a/scripts/functions/installer +++ b/scripts/functions/installer @@ -855,6 +855,12 @@ setup_user_profile() profile_file="$HOME/.bash_profile" fi + if [[ -d /etc/profile.d ]] ; then + etc_profile_file="/etc/profile.d/rvm.sh" + else + etc_profile_file="/etc/profile" + fi + if ! grep '$HOME/.rvm/scripts/rvm' "$profile_file" >/dev/null 2>&1; then if [[ ! -s "${etc_profile_file}" ]] ; then echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*' >> "$profile_file"