Skip to content

Instantly share code, notes, and snippets.

@marcomalva
Created October 7, 2021 21:41
Show Gist options
  • Save marcomalva/e7664598b2df281de5aeb40eff2e598f to your computer and use it in GitHub Desktop.
Save marcomalva/e7664598b2df281de5aeb40eff2e598f to your computer and use it in GitHub Desktop.
[AppImage to Gnome Desktop Application]Turn an appimage into a gnome desktop application #appimage #gnome3

Adding an AppImage as a Gnome Application

Six steps from donwloading an appimage to making it available as a Gnome desktop application. The examples assume that one stores the appimage files in folder /opt/var/AppImage/ but any folder will do.

  1. Download the appimage, e.g. cd /opt/var/AppImage/ && wget https://mirrors.mit.edu/kde/stable/digikam/7.3.0/digiKam-7.3.0-x86-64.appimage

  2. Set the executable bit, e.g. chmod u+x digiKam-7.3.0-x86-64.appimage

  3. Get an icon file (*.png) from the web, e.g. the github project page. If need be, crop it with e.g.: gthumb.

  4. Create the *.desktop file, for example digikam7.desktop:

#!/usr/bin/env xdg-open
[Desktop Entry]
Version=7.2.0
Type=Application
Terminal=false
Exec=/opt/var/AppImage/digiKam-7.3.0-x86-64.appimage -qwindowtitle %c
Name=DigiKam7
Comment=Professional Photo Management with the Power of Open Source
Icon=/opt/var/AppImage/1200px-Digikam_Oxygen.svg.png
Categories=Qt;Graphics;Photography;
X-DocPath=digikam/index.html
MimeType=x-content/image-dcf;x-content/image-picturecd;
GenericName=Photo Management Program
Terminal=false
StartupWMClass=digikam

For many applications the content will be simpler and lines can be removed or commented out.

  1. Create symbolic link: ln -s $(readlink -f digikam7.desktop) ~/.local/share/applications/

  2. Refresh the Gnome desktop application database: update-desktop-database ~/.local/share/applications

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment