3

Does anyone know how to put a launcher in the panel for an application during an rpm install? For example next to the firefox launcher.

I'm guessing it might involve moving the .desktop file into a directory during %post in the spec file?

The rpm is for a RHEL 6.1 system with gnome.

I'm creating an rpm from a spec file for a project I'm working on. I've also put a launcher into the Applications\Accessories menu using the .desktop file. I've been asked to put a launcher into the panel for the application and have tried searching with little success.

Any advice would be welcome.

jmhduck
  • 33
  • 3

1 Answers1

2

In GNOME 2 to manually add a launcher to the top panel, you need to put the same .desktop file, you used for Desktop Launcher, to $home/.gnome2/panel2.d/default/launchers/. Where $home should be resolved to the user's home path.

UPDATE

In addition to putting the launcher there you need to register it.

Just run /usr/lib/gnome-panel/gnome-panel-add --panel=top_panel_screen0 --launcher=<full path to your launcher>. You can also add --copy-launcher switch to make the tool copy the launcher to the user's launchers directory for you.

hellodanylo
  • 380
  • 3
  • 15
  • I've put the same .desktop file into the directory /home/user/.../launchers/ as suggested (for a user called user). I also logged in/out and the launcher hasn't appeared. It might be worth mentioning that there's no other files in that directory. – jmhduck Jul 04 '12 at 13:44
  • I've managed to get it working :D, although gnome-panel-add's location was a little different on my system /usr/libexec/gnome-panel-add I also just loaded the launcher from /usr/applications/launcherName.desktop – jmhduck Jul 05 '12 at 10:27