In Ubuntu there is no direct way to create shortcut for an application, but it can be done few steps. Below I am explaining the two method which can used to create shortcut for an application.
The above command will popup the GUI where you will be able to give all the details for the Application. Click OK after filling all the details and it will generate the shortcut on Desktop.
Alternately you can create the shortcut in ~/.local/share/applications/ to make it appear in applications dashboards, or in /usr/local/share/applications path to get access to all users. Replace ~/Desktop in above command with corresponding path.
Method 1
Using this method you may need to install gnome-panel , run the below command to install it
$ sudo apt install gnome-panel
Then Create launcher by running
$ gnome-desktop-item-edit --create-new ~/Desktop
The above command will popup the GUI where you will be able to give all the details for the Application. Click OK after filling all the details and it will generate the shortcut on Desktop.
Alternately you can create the shortcut in ~/.local/share/applications/ to make it appear in applications dashboards, or in /usr/local/share/applications path to get access to all users. Replace ~/Desktop in above command with corresponding path.
Method 2
In another way without installing gnome-panel, you can simply create a text file with .desktop extension and add following content to the fileMyApp.desktop
#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Exec=Application path or command to run
Name=Application name
Comment=Comment
Icon=path to the icon
Then save the file and close it. And make it executable by running
$ chmod 777 MyApp.desktop
No comments:
Post a Comment