1

I have created some .desktop files for some AppImages and they have all ran great up until I installed the Hyper Terminal. Now I get the following error:

Plasma

KDEInit could not launch 'Hyper':
Could not open library 'libkdeinit5_Hyper'.
Cannot load library libkdeinit5_Hyper: (libkdeinit5_Hyper: cannot open shared object file: No such file or directory)

I would like to fix this so that I can keep Hyper. I am using Kubuntu 18.04 with the latest updates. Will someone please help? Here is an example of the one I have for Minecraft:

[Desktop Entry]
Type=Application
Name=Minecraft
Comment=Minecraft
Icon=/home/AlphaGenius/Pictures/minecraft.png
Exec=/home/AlphaGenius/Minecraft/minecraft-launcher.sh
Terminal=true
Categories=Minecraft;Games
Name[en_US]=Minecraft.desktop

Here is another that I have for Cura:

[Desktop Entry]
Type=Application
Name=Cura
Comment=Cura
Icon=/home/AlphaGenius/Pictures/cura.png
Exec=/home/AlphaGenius/cura.AppImage
Terminal=true
Categories=Cura;Design
Name[en_US]=Cura.desktop

There may be better ways but I am just learning.

  • You mean you mention the terminal in the `Exec` line of the desktop file? Is that necessary? Please post an example. –  Jan 12 '19 at 19:07
  • 1
    I have updated my question with a couple of examples. – Dr. Jason Amerson Jan 12 '19 at 19:39
  • So, you do not use Hyper in the `Exec` lines, yet Hyper is started when you run the `desktop` files. That is odd. What happens when you execute other `desktop` files, like those in `usr/share/applications`? –  Jan 12 '19 at 19:43
  • btw: the Minecraft desktop file doesn't execute an AppImage file, does it? –  Jan 12 '19 at 19:51
  • I figure out what I was doing wrong. I have added an answer to my own question. Thanks for your help! – Dr. Jason Amerson Jan 12 '19 at 19:56

1 Answers1

1

The problem was the line Terminal=true.


I got it to work now. I added %U to the end of the exec line and then changed the terminal to false. Now it works like it should. Thank you @cipricus for helping me and leading me in the right direction. The modified script is as follows:

[Desktop Entry]
Type=Application
Name=Cura
Comment=Cura
Icon=/home/AlphaGenius/Pictures/cura.png
Exec="/home/AlphaGenius/cura.AppImage" %U
Terminal=false
Categories=Cura;Design
Name[en_US]=Cura.desktop
  • What does the `%U` mean? And did you fix the Minecraft launcher the same way? – wjandrea Jan 12 '19 at 20:00
  • 1
    I haven't noticed the `Terminal=true` line. That is the cause, you can simply remove the `Terminal` line altogether, and I think `%U` is not needed if all you want is execute the program. It would be needed (%f, %F, %u or %U) if you want to open files with it by selecting them. But then you need the `Mimetype` line. –  Jan 12 '19 at 20:04
  • @wjandrea - https://askubuntu.com/q/30210/47206, but I guess such arguments are not necessarily needed, unless you use the application in order to launch multiple selected files. –  Jan 12 '19 at 20:05
  • @cipricus - I think you are right about the Terminal line. – Dr. Jason Amerson Jan 12 '19 at 20:09
  • note that in case you want to start/open/run/play files in an AppImage program (and associate file types to that program) you will need a `Mimetype=` line in your `.desktop` file. –  Jan 13 '19 at 13:03