Looking for a step by step guide to install ruby using termux on Android? Then you are on the right page. (Guide supports ruby 2/2.2/2.7.2).
Ruby is a popular high-level programming language with benefits such as the ability to build high-performance web applications, data science reports, and statistical analysis. It is open-source, dynamic, and accessible on any operating system. This programming language is platform-independent.
On the other hand, termux is an Android utility program for automating any task without needing root access. You can do a wide variety of tasks with termux, including web scraping, Python programming, ssh, Metasploit pentesting, VPS server management, and Instagram bots, Tor networking, etc. Your imagination is the limit.
Here in this tutorial, we are going to see a step by step guide to install ruby 2.0, 2.2 in termux on Android without root.
How to install ruby2.0 and ruby2.2 in Termux on Android
To install ruby, you need to install Termux terminal in your Android device and then you have to download and install Ruby packages from the resource server.
Let’s take a look at the steps:
Step 1: Install termux black terminal
Firstly, you must download and install the termux terminal on your Android smartphone. Ruby2 does not work in the official termux application, so you have to install unofficial termux black. Follow the below guide:
- First of all, run apt update.
- Then download termux black package, run the below command –
- And then run the below command to run the installer.
- That’s it. Termux black is now successfully installed in your device.
You should make sure that Termux has access to your local storage. Type and run this command “termux-setup-storage”. A pop-up box shall appear asking you to give permission, then tap “Allow”.
Step 2: Upgrade the packages
It is necessary to update all your binaries and packages in the terminal so that the ruby library does not produce unwanted warnings. Run the below command-
apt update && apt upgrade
Step 3: Remove older version of Ruby packages
The termux on your android device might be using an older version of Ruby. You may skip this step if your device’s terminal don’t have Ruby installed, otherwise run the command below.
apt remove ruby
Step 4: Install Ruby Packages
Now you can install a specific version of ruby in termux. For smooth performance, you are highly recommended to install ruby 2.0 or ruby 2.2 in your terminal. Run the below command.
apt install ruby2
That’s it. Ruby is now successfully installed in termux on your android device.
The biggest advantage of Ruby over Python is its community, better documentation, and seamless performance. It is compatible with most operating systems. You can use frameworks to build mobile applications, web applications, and data science reports. Termux, on the other hand, is a widely used terminal utility for Android with a variety of add-ons available at the f-droid store. Check out these articles about termux.
Please accept my sincere thanks for reading this article. I am hopeful that the above step-by-step guide can assist you to install ruby 2.0 and ruby 2.2 on your device without rooting it. Please leave a comment below if you have encountered any undesired errors or warnings.