The xdg desktop file specification allows for icons to be either a
absolute path just a name. If the name is not an absolute path,
a icon from a icon theme will be used. This commit changes the
desktop file to use a icon name and adds the icons to the default
theme (hicolor). This allows the user to choose an alternative icons
theme that will override the default icon.
The relevant specs:
https://specifications.freedesktop.org/desktop-entry-spec/latest/ar01s05.html
> Icon to display in file manager, menus, etc. If the name is an
> absolute path, the given file will be used. If the name is not
> an absolute path, the algorithm described in the Icon Theme
> Specification will be used to locate the icon.
https://specifications.freedesktop.org/icon-theme-spec/latest/ar01s07.html
> Installing Application Icons: [...] Minimally you should install a
> 48x48 icon in the hicolor theme. This means installing a PNG file
> in $prefix/share/icons/hicolor/48x48/apps.
https://specifications.freedesktop.org/icon-theme-spec/latest/ar01s03.html
> Icons and themes are looked for in a set of directories. By
> default, apps should look in $HOME/.icons (for backwards
> compatibility), in $XDG_DATA_DIRS/icons and in
> /usr/share/pixmaps (in that order).
https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html#variables
> $XDG_DATA_DIRS defines the preference-ordered set of base
> directories to search for data files in addition to the $XDG_DATA_HOME
> base directory. The directories in $XDG_DATA_DIRS should be
> seperated with a colon ':'.
> If $XDG_DATA_DIRS is either not set or empty, a value equal to
> /usr/local/share/:/usr/share/ should be used.
Originally we introduced this function because we thought empty
directories were causing path length issues on Windows, but it turns out
that it was a problem with Squirrel, so we can delete this code path
altogether.
Signed-off-by: Nathan Sobo <nathan@github.com>