File indexing completed on 2024-11-16 09:01:51
0001
0002
0003
0004 set -e
0005
0006 VERSION=3.1.2
0007
0008 function sep() {
0009 echo """
0010 $*
0011 ++++++++++++++++++++++++++++++++++++++++"""
0012 }
0013
0014 sep "install rbenv"
0015 if [ "$RBENV_ROOT" = "" ]; then echo "ERROR: source environ.sh first"; exit 1; fi
0016 git clone https://github.com/rbenv/rbenv.git .rbenv
0017
0018
0019
0020
0021
0022 sep "source environ"
0023 source environ.sh
0024
0025 sep "install ruby-build"
0026 mkdir -p "$(rbenv root)"/plugins
0027 git clone https://github.com/rbenv/ruby-build.git $(rbenv root)/plugins/ruby-build
0028
0029 sep "install ruby version $VERSION"
0030 export RUBY_BUILD_BUILD_PATH=.ruby
0031 mkdir -p RUBY_BUILD_BUILD_PATH
0032 rbenv install --verbose $VERSION
0033 rbenv local $VERSION
0034
0035 sep "done; now re-run source environ.sh to enable the new ruby installation"