Reputation: 1579
I'm using "yum" which has a very old version of Ruby. I'm on linux OS and quite new to it. How can I install a specific version of Ruby that isn't present in the package installer?
Note: I don't have the other package managers (rbenv / rmv etc).
Note2: I am connected to this Linux machine via putty. So I only have command-line access.
Upvotes: 0
Views: 336
Reputation: 5586
Without package managers and using yum, your last option is to build from source.
Building from Source
Of course, you can install Ruby from source. Download and unpack a tarball (EG: Ruby 3.0.2), then just do this:
$ ./configure
$ make
$ sudo make install
By default, this will install Ruby into /usr/local. To change, pass the --prefix=DIR option to the ./configure script.
REF: https://www.ruby-lang.org/en/documentation/installation/#building-from-source
Upvotes: 1