Skip to content

Instantly share code, notes, and snippets.

@akafael
Created December 3, 2016 16:53
Show Gist options
  • Save akafael/4b8724da166354e67a2eb057c42e3e38 to your computer and use it in GitHub Desktop.
Save akafael/4b8724da166354e67a2eb057c42e3e38 to your computer and use it in GitHub Desktop.
[Tutorial] Create a link on Linux

How to create a link on Linux

1. Create a file with extention .desktop whith the following content

$ gedit myProgram.desktop

Content:

[Desktop Entry]
Encoding=UTF-8
Version=1.0
Name=MyProgramName
GenericName= My Complete Program Name
Exec= /path/to/my/program.sh
Icon=/path/to/my/program/icon.png
Terminal=true
StartupWMClass=MyProgramGroupClass
Type=Application
Categories=Application;
Comment= This is the best program comment ever.

2. Copy your for the default Applications Link folder

Command for user only access

$ cp myProgram.desktop ~/.local/share/applications/myProgram.desktop

Command for all user access

sudo cp myProgram.desktop /usr/share/applications/myProgram.desktop

Changing Icon

You may save your icon in system place amoung the others at /usr/share/icons

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment