If you have ever wondered how to add desktop shortcuts to Ubuntu, fret no more!
Whenever I use Ubuntu, it is normally through command line. But recently, I have been using Ubuntu 16.04 Desktop in a VirtualBox container, almost solely as a C IDE. I’ve never really understood the workings of the GUI (properly) and have almost become used to finding it unnecessary, until now.
Unfortunately, adding icons to the desktop is a little more involved then just “right click, make shortcut” as you would in Windows, but it’s not too complicated.
In Windows, an icon is usually a direct link to an .exe file within the installation directory.
In Linux, it’s a script. It’s a file that tells the GUI environment the icon picture, the text to be displayed underneath the icon, and can house different configurations such as the name depending on local language settings for example.
To add an icon, you need to locate the folder where all of your installed software icons are stored.
The image above is what my folder looks like. Any one of these can be made into a Desktop shortcut.
Copy your desired application to your ~/Desktop folder.
You’re almost there. If you haven’t seen the icon appear, you can drag the icon out of your Desktop folder and onto the desktop. (or a reboot should make it appear)
Some of the default application names can be a bit misleading, and you can simplify them by editing the script manually.
In terminal, navigate to your Desktop folder. You will notice how the files actually have different names to the ones you see on the GUI. Open with a text editor.
The above example are the contents of the “gnome system settings .desktop” file. As you can see, there are quite a few settings in this file. If you wanted to change the icon name in GUI, you an edit the “Name” field and save the file. Now you should see the changed name on the desktop!