Skip to content

Commit

Permalink
Create and add $rvm_bin_path if necessary
Browse files Browse the repository at this point in the history
  • Loading branch information
meineerde committed Mar 31, 2011
1 parent 9e38679 commit 519a0b1
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions scripts/functions/installer
Expand Up @@ -276,6 +276,7 @@ create_install_paths()
for install_path in "${install_paths[@]}" ; do
[[ -d "$rvm_path/$install_path" ]] || mkdir -p "$rvm_path/$install_path"
done
[[ -d "$rvm_bin_path" ]] || mkdir -p "$rvm_bin_path"
return 0
}

Expand Down Expand Up @@ -767,6 +768,14 @@ if [ -n \"\${BASH_VERSION:-}\" -o -n \"\${ZSH_VERSION:-}\" ] ; then
ps1_set
fi
fi
# Add $rvm_bin_path to $PATH in necessary
if [[ \"\${rvm_bin_path}\" != \"\${rvm_path}/bin\" ]] ; then
regex=\"^([^:]*:)*\${rvm_bin_path}(:[^:]*)*\$\"
if [[ ! \"\${PATH}\" =~ \$regex ]] ; then
export PATH=\"\${rvm_bin_path}:\${PATH}\"
fi
fi
fi
" >> "${etc_profile_file}"

Expand Down

0 comments on commit 519a0b1

Please sign in to comment.