Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

executable file 145 lines (105 sloc) 2.283 kb
#!/usr/bin/env bash
export PS4 PATH
PS4="+ \${BASH_SOURCE##\${rvm_path:-}} : \${FUNCNAME[0]:+\${FUNCNAME[0]}()} \${LINENO} > "
set -o errtrace
if [[ "$*" =~ --trace ]] || (( ${rvm_trace_flag:-0} > 0 ))
then # Tracing, if asked for.
set -o xtrace
export rvm_trace_flag=1
fi
#Handle Solaris Hosts
if [[ "$(uname -s)" == "SunOS" ]]
then
PATH="/usr/gnu/bin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:$PATH"
else
PATH="/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/sbin:$PATH"
fi
if [[ -n "${rvm_user_path_prefix:-}" ]]
then
PATH="${rvm_user_path_prefix}:$PATH"
fi
shopt -s extglob
source "$PWD/scripts/functions/installer"
# source "$PWD/scripts/rvm"
#
# RVM Installer
#
install_setup
true ${DESTDIR:=}
# Parse RVM Installer CLI arguments.
while (( $# > 0 ))
do
token="$1"
shift
case "$token" in
(--auto)
rvm_auto_flag=1
;;
(--path)
rvm_path="$1"
shift
;;
(--version)
rvm_path="${PWD%%+(\/)}"
__rvm_version
unset rvm_path
exit
;;
(--debug)
export rvm_debug_flag=1
;;
(--trace)
export rvm_trace_flag=1
set -o xtrace
echo "$@"
env | GREP_OPTIONS="" \grep '^rvm_'
export PS4="+ \${BASH_SOURCE##\${rvm_path:-}} : \${FUNCNAME[0]:+\${FUNCNAME[0]}()} \${LINENO} > "
;;
(--help)
install_usage
exit 0
;;
(*)
echo "Unrecognized option: $token"
install_usage
exit 1
;;
esac
done
if [[ -n "${DESTDIR}" ]]
then
rvm_prefix="${DESTDIR}"
fi
determine_install_path
determine_install_or_upgrade
if [[ -z "${rvm_path:-}" ]]
then
echo "ERROR: rvm_path is empty, halting installation."
exit 1
fi
export rvm_prefix rvm_path rvm_debug_flag rvm_trace_flag
create_install_paths
print_install_header
configure_installation
cleanse_old_entities
install_rvm_files
install_rvm_hooks
ensure_scripts_are_executable
setup_configuration_files
install_binscripts
automatic_profile_setup
install_gemsets
install_patchsets
cleanse_old_environments
migrate_old_gemsets
migrate_defaults
correct_binary_permissions
root_canal
install_man_pages
setup_rvmrc
setup_user_profile
record_ruby_configs
cleanup_tmp_files
display_thank_you
display_notes
display_requirements
Jump to Line
Something went wrong with that request. Please try again.