Wednesday, April 10, 2013

Create a custom launcher icon in gnome-shell

Today, I realised that navigating into a certain folder to start mincraft with a terminal command is much to complicated. A nice minecraft icon within the other installed applications would be great!


All I needed to do was to create a file: ~/.local/share/applications/minecraft.desktop and fill it with such a content:
[Desktop Entry]
Encoding=UTF-8
Name=Minecraft
GenericName=Game
Comment=Block Building Game
Exec=java -Xmx1024M -Xms512M -jar /path/to/minecraft.jar
Icon=/path/to/minecraft/icon.png
Terminal=false
Type=Application
MimeType=text/plain;
Categories=Game;
Name[en_US]=Minecraft
You still need to download a beautiful icon and adopt the two lines in bold (path to your executable and to the icon). Further you need to run
chmod a+x ~/.local/share/applications/minecraft.desktop
to give this file proper rights for execution. This is it! It works for any other application/script too!

No comments:

Post a Comment