Installing Ruby Programming Language:
In order to run Ruby programs on RubyMine, you must have Ruby programming language installed on your machine.
On Ubuntu, you can install Ruby programming language with the following command:
Now, press y and then press <Enter> to continue.
Ruby should be installed.
On Ubuntu 16.04 LTS and later, RubyMine is available as a SNAP package. So, you can install the latest version of RubyMine on Ubuntu 16.04 LTS and later from the official SNAP package repository of Ubuntu.
To install RubyMine SNAP package on Ubuntu 16.04 LTS and later, run the following command:
Now, type in the password of your login user and press <Enter> to continue.
RubyMine snap package is being downloaded.
RubyMine is installed.
Initial Configuration of RubyMine:
Now, you can start RubyMine from the Application Menu of Ubuntu as you can see in the screenshot below.
As you’re running RubyMine for the first time, you may not have any settings to import. Just select Do not import settings and click on OK.
Now, you have to accept the JetBrains User Agreement. To do that, check I confirm that I have read and accept the terms of this User Agreement checkbox and click on Continue.
Now, select an UI theme and click on Next: Keymaps.
Now, select the keymap that you’re comfortable with and click on Next: default plugins.
Now, you can enable/disable certain features to tune RubyMine to your needs. Once you’re done, click on Next: Featured plugins.
Now, JetBrains will suggest you some popular plugins for RubyMine. If you like/need any of them, just click on Install to install it. Once you’re done, click on Start using RubyMine.
Now, you have to activate RubyMine. RubyMine is not free. In order to use RubyMine, you have to buy a license from JetBrains. Once you have the credentials, you can activate RubyMine from here.
If you want to try out RubyMine before you buy a license, you can do so for 30 days at the time of this writing. To do that, select Evaluate for free and click on Evaluate.
RubyMine is being loaded.
This is the dashboard of RubyMine. From here, you can create new projects and manage existing projects.
Creating a Ruby Project with RubyMine:
In this section, I will show you how to create a new Ruby project with RubyMine and run a simple Ruby program. So, let’s get started.
First, start RubyMine and click on Create New Project.
Now, select your project type. I selected Empty Project. Now, set your project Location (where RubyMine will save the files for this project) and make sure the Ruby SDK is correct. Once you’re done, click on Create.
A new project should be created.
Now, create a new file hello.rb and type in the following lines as shown in the screenshot below.
Once you’re done, click on the Play button as marked in the screenshot below to run the hello.rb Ruby program.
At times, the Play button I showed you earlier may be grayed out. Don’t worry. You can also run your favorite Ruby program from Rub > Run… as you can see in the screenshot below.
Now, select your Ruby program from the list.
Your desired Ruby program should be executed and the correct output should be displayed as you can see in the screenshot below.
So, that’s how you install RubyMine Ruby IDE from JetBrains on Ubuntu. Thanks for reading this article.