Ruby is an open-source, object-oriented, and general-purpose programming language which is one of the most popular programming languages.
Ruby programming language is the reason behind the powerful Ruby and Rails framework.
It also supports functional and object-oriented programming.
Ruby and Ruby on Rails differ from each other in a sense that the former one is a general-purpose programming language whereas the latter one is a web-based framework.
Here at LinuxAPT, as part of our Server Management Services, we regularly help our Customers to perform related Ruby related queries.
In this context, we shall look into how to install Ruby on a Ubuntu 20.04 system.
How to install Ruby on Ubuntu 20.04 ?
To install the latest available and compatible version of Ruby on your Ubuntu 20.04 system, following steps should be performed.
Then follow the steps given below.
1. Perform Ubuntu 20.04 System Cache's Update
We need to update our Ubuntu 20.04 system's cache by executing the command shown below:
$ sudo apt-get update
This command will get the system updated successfully.
2. Install the Latest Compatible Version of Ruby on your Ubuntu 20.04 System
Now, we need to install the latest available and compatible version of Ruby on our Ubuntu 20.04 system with the command shown below:
$ sudo apt install ruby-full
3. Verify the Successful Installation of Ruby on your Ubuntu 20.04 System
You can even verify the successful installation of Ruby on your Ubuntu 20.04 system by checking its version with the command shown below:
$ ruby --version
This will display the version of Ruby installed on Ubuntu system.
How to uninstall Ruby from Ubuntu 20.04 ?
To remove Ruby from your Ubuntu 20.04 system, you have to execute the command shown below:
$ sudo apt-get purge ruby
This command will remove Ruby and its configuration files from your Ubuntu 20.04 system.
Now, you can also remove the irrelevant packages and dependencies from your Ubuntu 20.04 system for freeing up the occupied space with the command shown below:
$ sudo apt-get autoremove
Running this command will free up a significant amount of your Ubuntu 20.04 system's space.
[Need urgent assistance in fixing Ruby related issues? We can help you. ]