Allow installing desktop files while installed as native
Plans had been made that we should release a build without flatpak's sandbox. Currently doing this will work fine for just playing the game, but for modding, this will become an issue due to the lack of a URI scheme being installed to the system.
The solution should be as simple as following these steps:
- Embed or generate a .desktop
- Can use what we have for flatpak as a base
- Change Exec to the location of the game's executable binary.
- Change Icon to
UnleashedRecomp
- Install desktop file and icon
- Desktop files can be installed/linked to
~/.local/share/applicationswith a name likeUnleashedRecomp.desktop - Icons files can be installed/linked to
.local/share/icons/hicolor/128x128/appswith a name likeUnleashedRecomp.png(Make sure to create the folder if missing) - Update applications cache by running
update-desktop-database ~/.local/share/applications
- Desktop files can be installed/linked to
- Register the mime type
- Just run
xdg-mime default UnleashedRecomp.desktop x-scheme-handler/unleashedrecomp
- Just run
For most Linux systems this should work without any issues.