Ruby

From Han Wiki
Revision as of 10:53, 23 July 2019 by Mhan (talk | contribs) (iwu)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Installing Ruby on CentOS

  • Last tested on CentOS 7.6.1810 (2019-07-23)
// install required packages
$ sudo yum install gcc-c++ patch readline readline-devel zlib zlib-devel libyaml-devel libffi-devel openssl-devel make bzip2 autoconf automake libtool bison iconv-devel sqlite-devel

// install RVM
$ curl -sSL https://rvm.io/mpapis.asc | gpg2 --import -
$ curl -sSL https://rvm.io/pkuczynski.asc | gpg2 --import -
$ curl -L get.rvm.io | bash -s stable

// load RVM environment
$ source /home/skan/.rvm/scripts/rvm
$ rvm reload

// verify dependencies
$ rvm requirements run

// check the list of Ruby versions available for installation
$ rvm list known

// install a specific version
$ rvm install 2.6

// check currently installed versions
$ rvm use 2.6 --default

// check which version is the default
$ ruby --version