By using this site you agree to the use of cookies.

Learn more

Share via:

Creating A Desktop Launcher For Eclipse

How to create a simple .desktop launcher for Eclipse in Ubuntu Gnome, and add it to your favorites.

Edited: 2017-09-24 14:37

By. Jacob

It is that time again. I had to reinstall Ubuntu, including Eclipse. And, as usual, I ran into a bunch of problems. Some of them are just the usual Linux BS, such as Eclipse not being installed properly, so you manually have to create a launcher. And, as we all know, even simple things like installing software can be severely complicated when the packages are not available in the repositories.

In the worst of cases, it will require expert knowledge to fix. Mostly, just a lot of wasted time Googling our way to solutions.

It is not that I think it is hard to create launchers personally. I just think it is unnecessary, retarded, and truly pathetic that Linux still struggle in this area. Ubuntu does not even have one of the GUI tools installed by default, but not even the GUI tools are very good. So, I actually prefer creating the Launchers manually. Linux developers have a lot to learn from Windows in this area.

Creating a launcher for Eclipse

In this example, I am creating the launcher for Eclipse Oxygen, the latest version. But it should work for any version.

1. Start by opening a Terminal, then type the below command to create a .desktop file:

sudo nano ~/.local/share/applications/eclipse.desktop

This will prompt you for your password to edit the file (you are actually creating it, if it does not exist).

2. Write the content to the file. The content of the file will be similar to the below, just remember to adjust the paths so they match your setup:

[Desktop Entry]
Comment=Eclipse Integrated Development Environment

Pres CTRL + O to write the changes, then press CTRL + X to exit.

3. Make the file executable:

chmod +x ~/.local/share/applications/eclipse.desktop

Done. You can now find the launcher when searching for Eclipse. Optionally, you can right-click on it, and add it to your favorites.