Ubuntu 中如何給 GoLand 設置桌面快捷圖標

首先,轉到 /usr/share/applications 路徑下,這個路徑存放的是系統所有的已設置應用的桌面圖標

cd /usr/share/applications

之後,通過命令 vim goland.desktop 創建一個 GoLand 的桌面快捷圖標,vim 後面的名稱自定義,後綴名必須是.desktop

編輯內容:

[Desktop Entry]
Encoding=UTF-8
Name=goland IDE
Comment=The Smarter Way to Code
Exec=/bin/sh "/usr/local/golang/bin/goland.sh"
Icon=/usr/local/golang/bin/goland.png
Categories=Application;Development;Java;IDE
Version=1.0
Type=Application
Terminal=0

其中,Exec 以及 Icon 根據自己安裝的 goland.sh 以及 goland.png 路徑去設置,其他的都保持一致。

注意: 編輯保存文件需要有 root 權限,所以,先登錄 root 用戶!

例如:

[Desktop Entry]
Encoding=UTF-8
Name=goland IDE
Comment=The Smarter Way to Code
Exec=/bin/sh "/home/wyj/mine/software/GoLand-2020.1.2/bin/goland.sh"
Icon=/home/wyj/mine/software/GoLand-2020.1.2/bin/goland.png
Categories=Application;Development;Java;IDE
Version=1.0
Type=Application
Terminal=0

之後,就可以找到 GoLand 圖標啦~
在這裏插入圖片描述

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章