歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux基礎 >> Linux教程

Ubuntu 12.04 添加Eclipse程序啟動器

Ubuntu 12.04 dash home中每個圖標對應/usr/share/applications當中的一個配置文件(文件名後綴為.desktop)。所以要在dash home中添加一個自定義程序啟動器,需要在該文件目錄下創建對應的配置文件。至於配置文件的語法,參考該目錄下的配置文件即可明白。

以eclipse為例,方法如下。

系統:Ubuntu 12.04 beta2 i386

方法:

1. 在/usr/share/applications目錄下創建eclipse啟動器配置文件

cd /usr/share/applications  
sudo gedit eclipse.desktop 

2. 編輯eclipse.desktop並保存。簡單的配置示例:
  1. #!/usr/bin/env xdg-open   
  2.   
  3. [Desktop Entry]   
  4. Version=1.0  
  5. Type=Application   
  6. Terminal=false  
  7. Icon[zh_CN]=/home/xxx/Software/eclipse/icon.xpm   
  8. Name[zh_CN]=Eclipse   
  9. Exec=/home/xx/Software/eclipse/eclipse   
  10. Comment[zh_CN]=Eclipse   
  11. Name=Eclipse   
  12. Comment=Eclipse   
  13. Icon=/home/xxx/Software/eclipse/icon.xpm  

這樣eclipse啟動器就添加到dash home中了:

Copyright © Linux教程網 All Rights Reserved