Saturday, June 18, 2016

How to create Desktop link (shortcut) for software in Ubuntu

If you are new to Ubuntu, You may have to face, that you have to use terminal to browse and run .sh files. When I was new to Ubuntu I had to face this. I’ve to type path of Intellij IDEA’s idea.sh file to run the IDE. Using terminal is nice but shortcut would be nice right?
Let’s Figure how to do it. Here I configure Intellij IDEA 14 (in 15 they ask if you want desktop entries or not.)
First we have to create the desktop link file with .desktop extension. You can use arbitrary valid name but after that .desktop extension should be there. Type below command in terminal.(Replace with Intellij.desktop your_Software_name.desktop)
gksudo gedit /usr/share/applications/Intellij.desktop
Below code you must Enter to the file and save it. (You might not install gksu in your Ubuntu, You can install it by sudo apt-get install gksu  Reason is not to use normal sudo is https://help.ubuntu.com/community/RootSudo#Graphical_sudo)
[Desktop Entry]
Name=Intellij 14
Type=Application
Exec=/home/dreamer/idea-IU-141.3056.4/bin/idea.sh
Terminal=false
Icon=/home/dreamer/idea-IU-141.3056.4/bin/idea.png
Comment=Integrated Development Environment
NoDisplay=false
Categories=Development;IDE;
Name[en]=Intellij
As you can Understand you Must change “Name” fields as your Application and “Exec” field with respective executable file (Normally in Linux software executable resides in bin folder as .sh file). If you want to give Icon you can use “Icon” field. Now you can type the name of software in Dash run it. If you use it frequently you can use very easy setup for it. Right click on running application’s icon on sidebar select Lock to Launcher. Now you can see it in side bar

No comments:

Post a Comment