Ruby

Application VersionCentOS 7: 2.0.0p648, CentOS 8: 2.5.5p157, Debian 9: 2.3.3p222, Debian 10: 2.5.5p157, Ubuntu 18.04: 2.5.1p57
LicenseRuby License, GPLv2, or 2-clause BSD
Websitehttps://www.ruby-lang.org, https://rvm.io/

Description

Ruby is a language that is more common in web development than in scientific computing, but it is included as part of a Cortex VM in case there is a program or script written in Ruby that you want to run.  Some examples of scientific tools written in Ruby include the gems (packages) included as part of SciRuby and BioRuby. Also included alongside Ruby is the RVM virtual environment manager, which allows you to use multiple versions of Ruby on the same host.

Using RVM

Before you or anyone on your server can use RVM, you (or another person) must be added to the rvm group using the following command (where username is substituted with a valid UNI or username):

(base) -bash-4.4$ sudo usermod -aG rvm username

Afterwards, you (or another user on your system) may need to log out and back in again for the change to take effect.  You can then get a list of all versions of Ruby that can be installed with the following command:

(base) -bash-4.4$ rvm list known

To install a version of Ruby you can use a command like the following:

(base) -bash-4.4$ rvm install ruby-2.7

And to use a particular version of Ruby:

(base) -bash-4.4$ rvm use ruby-2.7
Using /usr/local/rvm/gems/ruby-2.7.0
(base) -bash-4.4$ ruby -v
ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [x86_64-linux]

More information on how to use RVM can be found here.

Version History

DateLinux DistributionVersion
2020/07/27CentOS 72.0.0p648
2020/07/27CentOS 82.5.5p157
2020/07/27Debian 92.3.3p222
2020/07/27Debian 102.5.5p157
2020/07/27Ubuntu 18.042.5.1p57

Further Reading