Creating Menu Links to Samples for Linux Distribution

Hello All,

I would like to create a menu on Ubuntu to launch the PandaSamples.
I’ve tried to create a Panda3D.desktop file with following content:
[Desktop Entry]
Version=1.0
Encoding=UTF-8
Name=Panda3D GreetingCard
Comment=Manakel Menu for Panda3D
Exec=/usr/share/panda3d/samples/GreetingCard/ppython GreetingCard.py
Icon= Startup
Notify=true
Terminal=false
Type=Application
Categories=Application;Panda3d;Samples;

However my exec command is not good, its complains with following errors, do you have some ideas?
Details: Failed to execute child process “/usr/share/panda3d/samples/GreetingCard/ppython” (No such file or directory)

Is there such a file as /usr/share/panda3d/samples/GreetingCard/ppython ? I’m not sure how the Linux distribution is organized, but shouldn’t the command be something more like “/usr/share/panda3d/bin/ppython /usr/share/panda3d/samples/GreetingCard/GreetingCard.py”?

David

In the latest distro, there’s no difference between ppython and python. In fact, I’m trying to phase out the whole “ppython” thing.

So try this exec:

(cd /usr/share/panda3d/samples/GreetingCard ; python GreetingCard.py)

Hello , based on your command i found a beginning of solution

by putting the /usr/share/panda3d/samples/GreetingCard/ in a PATH keyword
and putting only python GreetingCard.py in the EXEC line i’ve got the following results:

  • a menu entry appears correctly in the menu
  • when i click on the launcher nothing happened :frowning:

BUT
if i put the .desktop file anywhere on the pc where i can click on it, then it works perfect …

So i should find now how to have the launcher works from the menu also
( this maybe not today, as i’m reinstalling my whole distros on another harddrive , first one was really too small (<3GB))