.desktop files for app-in-snap

Vasilisc vasilisc777 at gmail.com
Mon Aug 8 06:47:00 UTC 2016

08.08.2016 08:50, Didier Roche пишет:
> Le 06/08/2016 à 09:47, Vasilisc a écrit :
>>> Please help me. If I launch the program in the Terminal - well done, but
>>> I can't start program from Unity Launcher.
>>> I tried to change parameter Exec in
>>> ~/.local/share/applications/app.desktop
>>> Exec=app-name
>>> Exec=snap-name.app-name
>>> Exec=$SNAP/usr/bin/start-script.sh
>>> Exec=$snap.$app (http://snapcraft.io/docs/snaps/structure)
>>> and studied case
>>> https://github.com/ubuntu/snappy-playpen/blob/master/vlc/setup/gui/vlc.desktop
>>> but it didn't help.
>> suspect lines
>> Aug  6 10:20:35 vb gnome-session[2377]: (gnome-software:2582):
>> As-WARNING **: failed to rescan: Failed to parse
>> /home/vasilisc/.local/share/applications/org-languagetool-gui-main.desktop
>> file: cannot process file of type application/x-desktop
> Hey Vasilisc,
> You didn't provide your .desktop file in setup/gui/ directory. Do you
> mind doing this?
> I suspect your type is different from "Type=Application", which it
> should be.
> Didier

I found a problem. My script-wrapper (usr/bin/run.sh) run java app
.... bla-bla-bla ....
java -jar -Duser.home=$SNAP_USER_DATA $SNAP/usr/bin/languagetool.jar

in snapcraft.yaml
     command: usr/bin/run.sh
     plugs: [network, network-bind, x11, home, unity7]

If to attach the java-app to a panel Unity Launcher, then the file 
(~/.local/shape/applications/org-languagetool-gui-main.desktop ) will 

[Desktop Entry]
Name=LanguageTool 3.4-SNAPSHOT
Exec=java -jar -Duser.home=/home/vasilisc/snap/languagetool/x1 

In a host-system can't execute a command (it's impossible)
java -jar -Duser.home=/home/vasilisc/snap/languagetool/x1 

I don't know what to do.
Best regards,

More information about the Snapcraft mailing list