RVM also know as Ruby Version Manager is a command-line tool which allows you to easily install, manage, and work with multiple version of Ruby or environments from interpreters to sets of gems. Here is a really easy guide to install RVM on CentOS.
Curl.sudo yum install curl
This will install RVM.
\curl -sSL https:/ /get.rvm.io | bash -s stable
A reopen of Terminal is require to set the RVM environment variable.
exit # To close the Terminal
RVM is a really smart tool it figures by its self what Linux distribution you are using. We can now download the required tools to build Ruby on CentOS.
I will be installing the current stable version of Ruby using RVM. At the time of this post the latest version of Ruby is Ruby 2.1.1, So I will be installing it in using the command below, you can install any version of Ruby as you require by simply changing the version '2.1.1' by the version you prefer or require for your project.
rvm install 2.1.1
To set Ruby 2.1.1 as the default Ruby environment.
rvm use 2.1.1 --default
If you have issue with setting the default Ruby environment or get an error that says the command does not exits, You can fix that too by adding the lines below in your
Now we have Ruby installed on CentOS using RVM. If you have any problem feel free to leave a comment below.