I am trying to make a desktop shortcut to launch Spyder, which can be launched by typing spyder in terminal.

I made a spy.sh script with spyder in it. It works with bash spy.sh and ./spy.sh. But when I make a desktop shortcut like this:

[Desktop Entry]

It gives out an error:

"There was an error creating child process for the terminal. Failed to execute child process “/Desktop/spy.sh” (No such file or directory)"

Same error when I change into Exec=spyder

What should I do?


You don't need a script to do that, in a terminal just do

$ which spyder

This gives you the full path to the file that's executed, I suppose /usr/bin/spyder. Then just use that path for your Exec= line.


To configure KDE desktop shortcut to run specific command, you have to link the full path of the application.

i.e. use Exec=/home/(user)/Desktop/spy.sh instead of Exec=/Desktop/spy.sh (Because if you type /Desktop/spy.sh the system will actually find files from / --> /Desktop, which this folder will probably never exist.)

And for runing Spyder, follow dessert's answer.

Also, make sure spy.sh is executable, or else Permission denied will appear.

  • Thanks a lot. Even though linking full path helped remove the error, I couldn't run spyder successfully, a program would come up in taskbar called "web browser" and close. Following dessert's answer did the work. – Alekh Karkada Ashok Sep 19 '17 at 6:01
  • 3
    You probably have a corrupted spy.sh script. Also, if you find an answer working, mark the answer accepted by clicking the checkmark icon. – Cynplytholowazy Sep 19 '17 at 6:02
  • But it works when executed from terminal. BTW, why doesn't just writing spyder in Exec= work for me? (suggested here - stackoverflow.com/questions/39771849/…) – Alekh Karkada Ashok Sep 19 '17 at 6:04
  • 3
    Because the desktop environment won't automatically search for spyder for you. If you type export you will see something like PATH=/usr/bin... but KDE desktop won't check this parameter. – Cynplytholowazy Sep 19 '17 at 6:05
  • 2
    @AlekhKarkadaAshok I consider the automatic path completion a terminal feature, it's a good idea to give the full path everywhere else, especially in config files. – dessert Sep 19 '17 at 6:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.