27

How can I add an application to Applications > Internet in Gnome Desktop running on CentOS 6.4?

Per this old Docs link, it suggests to edit /etc/xdg/menus/applications.menu.

How can I add /home/danny/some/path/myprog/prog (executable) to my Gnome Applications menu?

0
31

This is how I did it:

vi /usr/share/applications/newitem.desktop
[Desktop Entry]
Version=1.0
Name=My Program
Exec=/home/danny/some/path/myprog/prog
Terminal=false
Type=Application
StartupNotify=true
Categories=Network;WebBrowser;
X-Desktop-File-Install-Version=0.15

An icon can be added by including Icon=/some/path.

6
  • 12
    Since this is an application in the 'danny' account, you could put it in ~danny/.local/share/applications/newitem.desktop, which will only show up in the 'danny' user's menus. – jsbillings Apr 1 '13 at 0:54
  • Is it possible to put run as sudo(root) option ? – Gossamer Sep 21 '13 at 9:41
  • 3
    any source or docs that describe what each field means? – spy Jun 16 '17 at 1:48
  • If your path contains white spaces, enclose it in quotes. – Line Apr 29 '20 at 14:32
  • 1
    @spy for posterity, here's the section of the .desktop file spec listing the recognized desktop entry keys: specifications.freedesktop.org/desktop-entry-spec/… – Ken Bellows Jan 22 at 13:01
12

There is another solution by enabling an edit menu option.

You can have this menu by installing the alacarte package with this command (as root):

yum install alacarte

After that, just restart your X server and you can edit your menus with a mouse right click on the toolbar.

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.