一,在桌面新建一个文件
文件名随意,但必须带有.desktop的后缀名, 以Eclipse为例
vi /home/lenmom/Desktop/eclipse.desktop
二,在文件中写入如下内容
[Desktop Entry]
Encoding=UTF-8
Name=Eclipse
Comment=Eclipse IDE for C/C++
Exec=/home/workspace/eclipse/eclipse
Icon=/home/workspace/eclipse/icon.xpm
Terminal=false
StartupNotify=true
Type=Application
Categories=Utility;TextEditor;Development;IDE;
Keywords=Eclipse;
三,给文件赋予可执行权限
chmod a+x /home/lenmom/Desktop/eclipse.desktop