On Linux, the AppImage's obsidian.desktop file is missing %u at end of Exec line, which is needed for xdg-open to work

Steps to reproduce

  • Install Obsidian on Linux from the AppImage download link
  • Create a vault called main and a file called start in it.
  • Close the start note in Obsidian.
  • On command line, run xdg-open obsidian://vault/main/start

Expected result

Running Obsidian instance opens up the start note.

Actual result

A new obsidian instance opens up, asking to select the vault - the same behaviour as running obsidian without a url

Environment

  • Operating system: Debian Linux
  • Obsidian version: 0.11.13

Additional information

The default .desktop file installed by AppImage in .local/share/applications/appimagekit_39876e19698f682fb7c53abcd04f3540-obsidian.desktop

contains

[Desktop Entry]
Name=Obsidian
Exec=/home/thomasvs/bin/Obsidian-0.11.13.AppImage %u
Terminal=false
Type=Application
Icon=appimagekit_39876e19698f682fb7c53abcd04f3540_obsidian
StartupWMClass=obsidian
X-AppImage-Version=0.11.13
Comment=Obsidian
MimeType=x-scheme-handler/obsidian;
Categories=Office;
TryExec=/home/thomasvs/bin/Obsidian-0.11.13.AppImage
X-AppImage-Comment=Generated by appimaged continuous-1-g6f3138f
X-AppImage-Identifier=39876e19698f682fb7c53abcd04f3540

If I update the Exec line to read
Exec=/home/thomasvs/bin/Obsidian-0.11.13.AppImage %u

then xdg-open works as expected.

https://help.obsidian.md/Advanced+topics/Using+obsidian+URI

There’s two problems with those instructions.

a) the .desktop file gets updated (and %u removed) on every upgrade. This page doesn’t mention that these instructions need to be repeated on every upgrade.

b) the AppImage should ship with a correct .desktop file to begin with, and instructions for the user on how to override shouldn’t be necessary. Why isn’t the AppImage correct?

Just leaving this here: Meta Post - Linux tips, tricks & solutions to common problems - #3 by argentum

I’m not sure what “upgrade” is removing the %u for you, might want to specify what you mean by “installing” and “upgrading”, since the AppImage doesn’t do it on its own (you’d have to download the newer version yourself).

As far as I can tell, I am running the 0.11.13 installer AppImage, and it has updated to 0.13.5 after enabling insider builds. Before
also had Automatic updates on, and as far as I can tell the .desktop file got rewritten after each update.

I

no, the update doesn’t touch the .desktop