GNU bug report logs - #79068
30.1; emacsclient.desktop: x-scheme-handler/org-protocol is inconsistent with %F

Previous Next

Package: emacs;

Reported by: Ulrich Müller <ulm <at> gentoo.org>

Date: Mon, 21 Jul 2025 08:42:02 UTC

Severity: normal

Merged with 74467

Found in versions 30.1, 31.0.50

Full log


View this message in rfc822 format

From: Ulrich Müller <ulm <at> gentoo.org>
To: 79068 <at> debbugs.gnu.org
Cc: Ihor Radchenko <yantar92 <at> posteo.net>
Subject: bug#79068: 30.1; emacsclient.desktop: x-scheme-handler/org-protocol is inconsistent with %F
Date: Mon, 21 Jul 2025 10:41:28 +0200
emacsclient.desktop advertises x-scheme-handler/org-protocol as a
supported MIME types, but uses the %F field code (i.e. a list of files)
in its Exec key.

According to the Desktop Entry Specification, a non-file MIME type like
x-scheme-handler/* must not be paired with %F but with %U.

KDE warns about this at runtime (e.g. when trying to open a file in its
Dolphin file manager):

kf.kio.core: "/usr/share/applications/emacsclient.desktop" contains supported protocols but doesn't use %u or %U in its Exec line! This is inconsistent.


Unfortunately, I don't see a good way to fix this. Replacing %F with %U
might work for some applications, but the spec says about the %U field
code: "Local files may either be passed as file: URLs or as file path.",
and passing file:// to emacsclient won't generally work.

I've also tried adding both %F and %U but it is not valid either:

$ desktop-file-validate emacsclient.desktop 
emacsclient.desktop: error: value "sh -c "if [ -n \\"\\$*\\" ]; then exec emacsclient --alternate-editor= --display=\\"\\$DISPLAY\\" \\"\\$@\\"; else exec emacsclient --alternate-editor= --create-frame; fi" sh %F %U" for key "Exec" in group "Desktop Entry" may contain at most one "%f", "%u", "%F" or "%U" field code




This bug report was last modified 5 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.