Table of Contents

Ruby

Installing Ruby with rbenv

rbenv allows you to manage multiple installations of Ruby. It does not support installing Ruby, but there is a popular plugin named ruby-build to install Ruby. Both tools are available for OS X, Linux, or other UNIX-like operating systems.

Installing rbenv

# yum install git
# cd /usr/local
# git clone git://github.com/sstephenson/rbenv.git

# echo 'export RBENV_ROOT="/usr/local/rbenv"' >> /etc/profile
# echo 'export PATH="${RBENV_ROOT}/bin:${PATH}"' >> /etc/profile
# echo 'eval "$(rbenv init -)"' >> /etc/profile 

# mkdir /usr/local/rbenv/plugins
# cd /usr/local/rbenv/plugins
# git clone git://github.com/sstephenson/ruby-build.git 

Installing rbenv

# yum install gcc make openssl-devel 
# rbenv install -l

# rbenv install 2.1.0


# rbenv global 2.1.0  <- Setting Default Ruby Version

# ruby -v