The Scenario:
You have an .AppImage file and would like to treat it like an installed Linux app.
The solution:
Create a custom .desktop file
For this article, I'll use the following constraints:
Let's do it.
NOTE: You might have to use
sudo
commands to access files in the/bin
and/usr
directories
- Download the .AppImage file and an icon you would like to register it with
- Move the .AppImage file to the path
/bin
, e.g.sudo mv ~/Downloads/Marktext.AppImage /bin/
- Make it executable with
sudo chmod +x /bin/Marktext.AppImage
- Save the icon under
/usr/share/icons/custom/markdown.png
e.g.sudo mkdir --parents /usr/share/icons/custom
&&sudo mv ~/Downloads/markdown.png /usr/share/icons/custom/
- Create a .desktop file under
~/.local/share/applications/marktext.desktop
- Paste the following content into it (make sure to remove the comments):
[Desktop Entry]
Name=Mark Text
Comment=Next generation markdown editor
Exec=/bin/marktext-x86_64.AppImage # replace with your .AppImage
Terminal=false
Type=Application
Icon=/usr/share/icons/custom/markdown.png # replace with your icon
Categories=Office;TextEditor;Utility;
MimeType=text/markdown;
Keywords=marktext;markdown; # add searchable keywords
StartupWMClass=marktext
Actions=NewWindow;
That should do it. Try pressing the Super
key now and search for the app.
Hitting enter should then start up your application.
Top comments (1)
Nowdays in ubuntu, you have AppImageLauncher, which handles it automatically when you click on an AppImage file.