unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#67736: 30.0.50; emacsclient.desktop fails with quoting-related error
@ 2023-12-10  0:13 Mekeor Melire
  2023-12-10  6:17 ` Eli Zaretskii
  0 siblings, 1 reply; 12+ messages in thread
From: Mekeor Melire @ 2023-12-10  0:13 UTC (permalink / raw)
  To: 67736

In GNU+Linux, in Xorg, with xdg-utils installed, and with
emacsclient.desktop[1] from Emacs repository installed, configure the
mapping from mime-types to applications by creating a file
~/.config/mimeapps.list with contents:

    [Default Applications]
    text/plain=emacsclient.desktop

Create a plain-text file and open it with the XDG default application:

    echo hello > example.txt
    xdg-open example.txt

I expect Emacsclient to start and open the file. Instead, I get the
following error messages which point to quoting-related problems.

    $ xdg-open example.txt
    egrep: warning: egrep is obsolescent; using grep -E
    [: -c: line 1: unexpected EOF while looking for matching `"'
    [: -c: line 2: syntax error: unexpected end of file
    [: -c: line 1: unexpected EOF while looking for matching `"'
    [: -c: line 2: syntax error: unexpected end of file
    [: -c: line 1: unexpected EOF while looking for matching `"'
    [: -c: line 2: syntax error: unexpected end of file

Apparently, since the default application Emacsclient exits with
failure, xdg-open then proceeds by trying out other applications that
have an installed .desktop-file. Thus another program opens the file.

Does anyone else experience this problem?

It seems like it is a problem introduced with bug#49195 / commit
cbf220bc31c0a00c45b22c140eda7854d81d991b [2]. All versions of the Exec=
line of emacsclient.desktop result in the same erroneous behavior for me
since this commit. I.e. the last version that works is just:

    Exec=emacsclient -c %F

Please let me know if you can or cannot reproduce this, because it might
also possibly be a bug in my OS distribution, GNU Guix System.

By the way, I'm using the latest version of xdg-utils, 1.1.3, probably
released on 2018-05-10.



In GNU Emacs 30.0.50 (build 1, x86_64-unknown-linux-gnu, Motif Version
2.3.8, cairo version 1.16.0)
Windowing system distributor 'The X.Org Foundation', version 11.0.12101004
System Description: Guix System

Configured using:
 'configure
 CONFIG_SHELL=/gnu/store/rib9g2ig1xf3kclyl076w28parmncg4k-bash-minimal-5.1.16/bin/bash
 SHELL=/gnu/store/rib9g2ig1xf3kclyl076w28parmncg4k-bash-minimal-5.1.16/bin/bash
 --prefix=/gnu/store/whmdrrv8db90a238jgjy24hd13diljfl-emacs-next-motif-30.0.50-1.9d27b95
 --enable-fast-install --build=x86_64-unknown-linux-gnu
 --with-x-toolkit=motif --with-modules --with-native-compilation=aot
 --disable-build-details'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES
NATIVE_COMP NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3
THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER X11 XDBE XIM XPM MOTIF ZLIB



[1]  https://git.savannah.gnu.org/cgit/emacs.git/tree/etc/emacsclient.desktop
[2]  https://git.savannah.gnu.org/cgit/emacs.git/commit/etc/emacsclient.desktop?id=cbf220bc31c0a00c45b22c140eda7854d81d991b





^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2023-12-18 12:14 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-10  0:13 bug#67736: 30.0.50; emacsclient.desktop fails with quoting-related error Mekeor Melire
2023-12-10  6:17 ` Eli Zaretskii
2023-12-10 11:14   ` Mekeor Melire
2023-12-10 11:28     ` Mekeor Melire
2023-12-10 11:56       ` Eli Zaretskii
2023-12-17  0:14         ` Mekeor Melire
2023-12-17 14:24           ` Peter Oliver
2023-12-17 15:35             ` Ulrich Mueller
2023-12-17 23:06               ` Mekeor Melire
2023-12-18 10:17                 ` Ulrich Mueller
2023-12-18 12:14                   ` Mekeor Melire
2023-12-10 11:54     ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).