How to install Eclipse IDE on Ubuntu

Eclipse is a free and open-source IDE designed with an intuitive UI and powerful features like auto cleanup, import format, and code comparison. If you are looking for a good IDE platform to design apps and manage code, then Eclipse IDE should be on your list.

Eclipse is a popular Java Integrated Development Environment or IDE. It is written mostly in Java, and its high usage is seen for developing Java applications. Still, it may also be used to develop applications in other programming languages using plug-ins. If you are looking for a good IDE platform to design apps and manage code, then Eclipse IDE should be on your list.

Why IDE?

You don’t need an IDE to write a program. The good old simple text editors will suffice for simple applications that are easier to manage. But, as the program goes complex, it’s no brainer to have an IDE so that you can do things such as syntax highlighting, organizing the file structure, compiling, editing source code, and debugging.

Eclipse IDE Features

Eclipse Bash Editor Debugging
Eclipse Bash Editor Debugging

Eclipse is a great free and open-source platform built with an intuitive UI, and I highly recommend it due to these top features that come in handy while creating software.

  • It can offer fixes for simple programing mistakes when it detects them.
  • It lets you autoformat your source code using the Source > Format option.
  • It helps you clean up the imported statements in your source code.
  • Eclipse built-in dual-source view editor pane lets you compare two files graphically.
  • It provides abbreviations for common items by using Ctrl+Space while typing in the command.

Install & configure Eclipse IDE on Ubuntu

However, before starting in the installation steps, you need to make sure that your Ubuntu is updated using the following  commands:

sudo apt update
sudo apt upgrade

Installing Oracle Java on Ubuntu

Step 1. To install Eclipse on your machine, you need to install Java as a prerequisite. Add the following Oracle Java repository to your system repositories.

sudo add-apt-repository ppa:linuxuprising/java

Add Oracle PPA Repository

The below message indicates that some versions of Java are no longer available for download. Just press the “Enter” button to continue.

Press Enter To Confirm
Press Enter To Confirm

Step 2. Now let’s update the system repositories.

sudo apt update

Update System Repository
Update System Repository

Step 3. Next, install the Oracle Java installer using the below command:

sudo apt install oracle-java14-installer

Install Oracle Java Installer
Install Oracle Java Installer

Step 4. In the package configuration screen, press the “OK” button.

Configure Oracle Java Installer
Configure Oracle Java Installer

Step 5. Accept the license agreement by selecting the “Yes” option.

Accept License Agreement
Accept License Agreement

Step 6. Now you need to set the Oracle Java as default.

sudo apt install oracle-java14-set-default

Ensure Oracle Java Is Set To Default
Ensure Oracle Java Is Set To Default

Step 7. To ensure that the Oracle Java was installed successfully, execute the next command.

javac -version

Oracle Java Installed Successfully
Oracle Java Installed Successfully

Installing Eclipse

At this point, you should have installed Oracle Java on your machine. Our next step is to install Eclipse. Although the Ubuntu snap store lets you install Eclipse using the command below, I don’t recommend it as the version of the EclipseEclipse is old.

sudo snap install eclipse --classic

Recommended Method

Step 1. Instead of snap, let’s download the latest EclipseEclipse from the official source. From your favorite browser, open the official Eclipse IDE website. Then download the Eclipse package.

Download Eclipse IDE Package

Get Eclipse IDE
Get Eclipse IDE

Step 2. Save the package.

Save Eclipse File
Save Eclipse File

The download is in progress.

Download Inprogress
Download Inprogress

Step 3. After the download finishes, successfully extract the downloaded package using the next command.

tar xfz ~/Downloads/eclipse-inst-linux64.tar.gz

Extract Eclipse Package Content
Extract Eclipse Package Content

Step 4. Let’s run the Eclipse Installer using the following command:

eclipse-installer/eclipse-inst

Run Eclipse Installer
Run Eclipse Installer

The installer should start soon.

Eclipse Installer Will Start Soon
Installer Will Start Soon

Step 5. When the installer opens up, you can choose the version you need.

Select Eclipse IDE You Need To Install
Select Eclipse IDE You Need To Install

Step 6. Let’s install the Eclipse IDE for Developers.

Install Eclipse
Install Eclipse

Step 7. Accept the license agreement.

Accept Eclipse IDE License Agreement
Accept Eclipse IDE License Agreement

Installation in progress.

Installation Progress
Installation Progress

Step 8. After the installation completes successfully, you can launch it.

Launch The Installed Eclipse
Launch The Installed Eclipse

Configuring Eclipse

Step 1. Now to create a launcher for an application open the next file:

vi .local/share/applications/eclipse.desktop

Step 2. Copy the below content and paste it in the previous file. Do not forget to replace the USER_NAME with your username.

[Desktop Entry]
Name=Eclipse
Type=Application
Exec=/home/USER_NAME/eclipse/
Terminal=false
Icon=/home/USER_NAME/eclipse/icon.xpm
Comment=Integrated Development Environment
NoDisplay=false
Categories=Development;IDE;
Name[en]=Eclipse
Name[en_US]=Eclipse

Save the file and exit it.

Step 3. Finally, enter the following command to enable the shortcut icon.

sudo desktop-file-install eclipse.desktop

Conclusion

That’s all about installing and configuring Eclipse IDE on your Ubuntu system. I hope you liked the tutorial. What do you think of Eclipse? What’s the best feature in it that you like using it frequently? Do let our reader know in the comments below.

Hend Adel
Hi! I'm Hend Adel, a freelancer technical geek with successful experience in Database, Linux and many other IT fields. I help to build solutions to suit business needs and creating streamlined processes. I love Linux and I'm here to share my skills via FOSS Linux! Thanks for reading my article.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

STAY CONNECTED

23,283FansLike
386FollowersFollow
16SubscribersSubscribe

LATEST ARTICLES

MUST READ

Buyers who wish to go for a machine that is based on Linux often show interest in Chromebooks due to the form factor and extended battery life capabilities. Although ChromeOS power these machines, users can still miss out on a more genuine Linux experience. For those who happen to agree, the new Lemur Pro by System76 might get some heads turning.
Linux is growing faster than ever. As per the latest report, there is a drop in the Windows 10 market share for the first time, and Linux's market share has improved to 2.87% this month. Most of the features in the list were rolled out in the Pop OS 20.04. Let's a detailed look into the new features, how to upgrade, and a ride through video.

The 6 Best Linux File Recovery Software

Now and then, most of us lose important data in our computers either through accidental deletion, virus attacks, permanent removal of files, etc. Some of these files contain critical information that cannot be assumed and needs recovery. In this post, we will discuss some of the best data recovery available for Linux systems. The fantastic part is that most of them are opensource and freely available for use.

Ubuntu MATE 20.04 LTS Review: Refinement at its Best

Ubuntu MATE 20.04 LTS was released a week ago after two years of development. Official updates and security patches will be provided until April 2025. I have installed it on my test laptop for a spin and here are my observations based on almost a week usage.

Installing an updatable Manjaro Linux on a USB Flash Drive

In this tutorial, we will show step by step how to install a Manjaro on a USB flash. For those new to this distro, it is a light-weight distro that is based on Arch Linux. Arch Linux is known for its simplistic approach and is typically made for Linux pros, but Manjaro bridges the gap between user-friendliness and rock-solid performance.

CentOS vs. Fedora: Key Differences

Both Fedora and CentOS are RPM-based Linux distributions. The two share a lot of features in common but still have several differences. In this post, we introduce both Fedora and CentOS and look at their key differences in this comparison article.