Menu launcher doesn't work with parameters

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Hitmark7
Level 1
Level 1
Posts: 5
Joined: Tue Jan 29, 2013 2:53 am

Menu launcher doesn't work with parameters

Post by Hitmark7 »

Hi everybody.

I'm trying to create a menu launcher for the old Hexen game in my Linux Mint 13. In order to do this, I need to run DOSbox with some parameters. I've made the launcher directly on the desktop and it works fine, but adding it to the main menu seems to break the DOSbox parameters. It runs without they. This is the content of the launcher file:

Code: Select all

#!/usr/bin/env xdg-open

[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Categories=Games;
Icon=/media/Datos/Joan/Juegos/MS-DOS/Hexen/hexen.png
Name=Hexen - Beyond Heretic
Comment=Id Software, 1995
Exec=dosbox -c 'cd Hexen' -c 'hexen.EXE' -scaler normal3x
If I run it from ~/Escritorio/Hexen.desktop and it works fine, but from ~/.local/share/applications/Hexen.desktop , the default path for menu launchers, runs dosbox without the specified parameters.

Is this a bug? I've made some mistake?

Thanks for your replies!
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
viking777

Re: Menu launcher doesn't work with parameters

Post by viking777 »

Try it without the shebang: #!/usr/bin/env xdg-open
Dot Desktop files don't have a shebang - at least not any that I have got.
I don't guarantee that is the answer but it's worth a try.
Hitmark7
Level 1
Level 1
Posts: 5
Joined: Tue Jan 29, 2013 2:53 am

Re: Menu launcher doesn't work with parameters

Post by Hitmark7 »

I've removed the shebang and nothing changed. Also, I have a lot of auto generated shebanged .desktop files here at ~/.local/share/applications .

Curiosly, trying to open the shebanged files makes Pluma to hang. I had to edit they with Kate or Nano.
Locked

Return to “MATE”