Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Insufficiently escaped space-containing file path in generated .desktop file #334

Open
michal-kurz opened this issue Feb 6, 2024 · 1 comment

Comments

@michal-kurz
Copy link

I am not sure if this is a fault with apx, but it may be. Sorry if it's not, just close the issue then.

I installed the .deb package of Mullvad VPN client via sudo apt install ./mullvad.deb, and the following .desktop file was generated for it:

[Desktop Entry]
Name=Mullvad VPN on vso-pico
Exec=/usr/share/apx/distrobox/distrobox-enter  -n apx-vso-pico -- /bin/sh -l -c  "/opt/Mullvad VPN/mullvad-vpn"  %U
Terminal=false
Type=Application
Icon=mullvad-vpn
StartupWMClass=Mullvad VPN
Comment=Mullvad VPN client
Categories=Network;

When trying to run the app, it fails trying to locate /opt/Mullvad - the space in the Mullvad VPN folder name is not properly escaped. Wrapping the path into an extra pair of single quotes resolves this: /bin/sh -l -c "'/opt/Mullvad VPN/mullvad-vpn'" %U.

Not sure if this is problem with apx not escaping the path sufficiently, or with something else.

@kemzeb
Copy link

kemzeb commented Mar 11, 2024

I'm not familiar with VanillaOS; however, from reading this issue, the problem might be with the distrobox-enter command. Before 1.4.2.1 they suggest in their docs to "use single quotes around your double quotes". But for future versions this was no longer necessary because of this PR.

This seems to exactly match the problem you are having, but seeing that apx is using distrobox v1.6.0.1 this might not be the case (unless if distrobox-enter regressed after some time).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants