Linux Mint 18.3 Sylvia x64 Cinnamon
Kernel 4.15.0-36-generic
Ubuntu 16.04.1
Cinnamon 3.6.7
PROBLEM .desktop file is ignored / no menu entry appears in Mint Menu
DETAILS
I want to add an entry for a game to the Mint Menu during the installation of the app.
After the game has been installed to /usr/games and /usr/share/games, I want to set up the menu entry in the postinstall script.
I tried:
1. Place a .desktop file in directory /usr/share/applications
cp /usr/share/games/MyGame/pkg/MyGame.desktop /usr/share/applications
Code: Select all
[Desktop Entry]
Version=1.0
Type=Application
Name=MyGame
Comment=Some description
Exec=/usr/games/MyGame
Icon=/usr/share/games/MyGame/pkg/mygame.png
Terminal=true
Categories=Game;
2. Install the .desktop file using command desktop-file-install
desktop-file-install --dir=/usr/share/applications /usr/share/games/MyGame/pkg/MyGame.desktop
Result:
a) .desktop file is installed in /usr/share/applications correctly
b) an additional line is added to the .desktop file:
"X-Desktop-File-Install-Version=0.22"
c) Menu entry does NOT appear in Mint Menu
3. Check syntax of .desktop file using desktop-file-validate
desktop-file-validate /usr/share/applications/MyGame.desktop
Result: reports no errors, still the desktop file is ignored
4. Update Desktop database
sudo /usr/bin/update-desktop-database
Result: still no menu entry
5. Log out and log in, reboot
Result: still no menu entry
REMARKS
I saw a lot of reports about similar problems in different Ubuntu/Mint/Cinnamon forums, but found no solution.
But some programmers have successfully implemented menu entries into their packages.
Has someone got a hint for me?