---

How to create a desktop launcher in GNU/Linux

In the following article we’ll show you how to create a desktop launcher in GNU/Linux system.

What are Desktop Entries?

The freedesktop Desktop Entry specification provides a standard for applications to integrate into a desktop environment. Desktop entries are the configuration files that describe how an application is launched and which data it can handle. They also configure how an application appears in a menu with an icon, which is subject to the related menu specification standard.

The most common desktop entries are the .desktop and .directory files. This article explains how one can create a .desktop configuration file and easily create an application shortcut.

Desktop Application Entries

Desktop entries for applications, or .desktop files, are generally a combination of meta information resources and a shortcut of an application. These files usually reside in /usr/share/applications or /usr/local/share/applications for applications installed system-wide, or ~/.local/share/applications for user-specific applications. User entries take precedence over system entries.

Create Desktop Application

To create a new ApacheDirectoryStudio.desktop application, create a simple file containing something like this:

[Desktop Entry]
Name=Apache Directory Studio
Comment=LDAP Browser
Exec=/opt/apache-directory-studio/ApacheDirectoryStudio
TryExec=/opt/apache-directory-studio/ApacheDirectoryStudio
Icon=/opt/apache-directory-studio/ApacheDirectoryStudio.xpm
StartupNotify=false
Terminal=false
Type=Application
Categories=Network;

and install it using the xdg-desktop-menu command , for example:

xdg-desktop-menu install –novendor ./ApacheDirectoryStudio.desktop

That’s it

If you’re one of our Linux VPS Hosting customers we can help you create a desktop application shortcut on your virtual server free of charge. Just contact us and some of our experts will complete your request immediately.

Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends, & analysis