You need to do three things to make it work.
You already did one, which is you named the script ending in .sh
The second thing you need to do is make sure the file is visible to the user, so if the user is "boinc" then the file should be visible to the user "boinc" too. run ls -l and see if the user, group, other settings are set to allow this.
The third thing you need to do is indicate the script is "executable".
So it needs to at minimum be marked x for the user (and group, and other too if you put it in a shareable directory where others can use it too, but not needed for a private user desktop).
I have this setup for boinc.
- Code: Select all
[boinc@home ~]$ ls -l boinc.sh
-rwxr-xr-- 1 boinc boinc 50 Aug 15 2016 boinc.sh*
[boinc@home ~]$ cat boinc.sh
#!/bin/sh
cd "/var/lib/boinc/" && exec boincmgr $@
[boinc@home ~]$
This is probably not important, since your default is probably set to bash, but some environments use sh.
For example cron jobs run at kernel level may likely be sh and not bash, so you may want to convert the bash to sh on your script.
edit: just saw "executable" on permissions, my error.
edit: try naming the desktop file something.sh instead of something.desktop (I recall having to do this on and older desktop).