From: Eli Zaretskii <eliz@gnu.org>
To: Mekeor Melire <mekeor@posteo.de>
Cc: 67736@debbugs.gnu.org
Subject: bug#67736: 30.0.50; emacsclient.desktop fails with quoting-related error
Date: Sun, 10 Dec 2023 08:17:37 +0200 [thread overview]
Message-ID: <83cyvewpha.fsf@gnu.org> (raw)
In-Reply-To: <87a5qiswvy.fsf@posteo.de> (message from Mekeor Melire on Sun, 10 Dec 2023 00:13:33 +0000)
> From: Mekeor Melire <mekeor@posteo.de>
> Date: Sun, 10 Dec 2023 00:13:33 +0000
>
> 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.
Why does emacsclient exit with a failure in that case? When I try
invoking emacsclient from the shell prompt, it exits with a zero exit
status, not with a failure.
> 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
What is the command that is run with the current emacsclient.desktop
file?
next prev parent reply other threads:[~2023-12-10 6:17 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
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 [this message]
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
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83cyvewpha.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=67736@debbugs.gnu.org \
--cc=mekeor@posteo.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.