将应用程序添加到系统菜单

LINUX2010-11-21 12:53

比如我有一个文件DeenGui.desktop,现在要把它放进系统菜单中的「Applications->Programming」里面,要先将其拷贝到「/usr/share/applications/」中:
sudo cp /home/icyomik/Bash/DeenGui.desktop /usr/share/applications/
然后编辑该文件:
sudo gedit /usr/share/applications/DeenGui.desktop
内容如下:

#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Name=DeenGui
Icon=gdu-encrypted-lock
Exec=/home/icyomik/Bash/deengui.sh
Categories=Development;

如果关键字正确,那么关键字会变成红色背景,下面给出各个菜单关键字,关键字用分号「 ; 」隔开:

System->Preferences:         Settings;
System->Administration:      System;Settings;
Applications->Accessories:   Utility;
Applications->Games:         Game;
Applications->Graphics:      Graphics;
Applications->Internet:      Network;
Applications->Office:        Office;
Applications->Programming:   Development;
Applications->Sound & Video: AudioVideo;
Applications->System Tools:  System;

原文链接: http://blog.jtwo.me/add-the-application-to-the-system-menu