summaryrefslogtreecommitdiff
path: root/x11-misc/emacs-desktop-mail
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-03-07 17:57:54 +0000
committerV3n3RiX <venerix@koprulu.sector>2023-03-07 17:57:54 +0000
commitbc75b42f7650c33ffdb61e5e29b0b96cb9111932 (patch)
tree867908c0cf83e6015a5b1544cfdc4e17f1c13753 /x11-misc/emacs-desktop-mail
parentb3fef92e618039dc93153a93176184a49606c74a (diff)
gentoo auto-resync : 07:03:2023 - 17:57:54
Diffstat (limited to 'x11-misc/emacs-desktop-mail')
-rw-r--r--x11-misc/emacs-desktop-mail/Manifest2
-rw-r--r--x11-misc/emacs-desktop-mail/emacs-desktop-mail-1.2.ebuild (renamed from x11-misc/emacs-desktop-mail/emacs-desktop-mail-1.1.ebuild)17
2 files changed, 13 insertions, 6 deletions
diff --git a/x11-misc/emacs-desktop-mail/Manifest b/x11-misc/emacs-desktop-mail/Manifest
index 343711b09657..1d28b1823711 100644
--- a/x11-misc/emacs-desktop-mail/Manifest
+++ b/x11-misc/emacs-desktop-mail/Manifest
@@ -1,2 +1,2 @@
-EBUILD emacs-desktop-mail-1.1.ebuild 1448 BLAKE2B 0d41c090aa8e7df6d53c41022bdd5a8e020e63b4cf2fd767a586c9fb898c17dc4a4696a345ff1a53adda50a6c7f738d1d17ac90c7a03b36d714db5417f713e2f SHA512 a803538db4cb35f7d87dc721c78663fb3e6e5795e80f9fb99feb0849be0d05b1c409c3a346349a396c8286dd30e38eb0833273cb25bec3c7bc61d66d32db0d01
+EBUILD emacs-desktop-mail-1.2.ebuild 1728 BLAKE2B 4ab3eb9c9891b69d0c0be6849f74fb7c5333becdce9e75d1e583ce72272bfb1aede52612b8d9efaf543eea1c9bb4c254aff49df965daa90c7c144043ea74f1cf SHA512 9397589a8cbe5aa350dea87fdc81e6d25e33ee551bf60e29ff551f4c4fc47b549ff5ac2be777588e244e2a23ef46e665ac383aa670844c36838e3b82e485fedd
MISC metadata.xml 283 BLAKE2B 81c49021199f71096079a27f9121390fb8c1285c54b9478583ff2d647277fa106ef12456d7097c4be092fc48b514a1adcf855ca0fac911598232ef9eb7f102c0 SHA512 f32b303760addf5d4db8d18bd10fb677353cdfa4c5e545d47804ef756cf5e5a21f8b8efb631b08f802185913ceb98da820e404e06eb03d01fe9ea85c10d1ac13
diff --git a/x11-misc/emacs-desktop-mail/emacs-desktop-mail-1.1.ebuild b/x11-misc/emacs-desktop-mail/emacs-desktop-mail-1.2.ebuild
index 92d93860fb2f..aa83394f2032 100644
--- a/x11-misc/emacs-desktop-mail/emacs-desktop-mail-1.1.ebuild
+++ b/x11-misc/emacs-desktop-mail/emacs-desktop-mail-1.2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -29,8 +29,12 @@ src_install() {
# The Desktop Entry Specification does not allow field codes like %u
# inside a quoted argument, therefore we need a shell wrapper.
- # We want to pass a literal '"(message-mailto \"$1\")"' in the -c
- # command, but in the desktop entry '"', '\', and '$' must be escaped
+ # We pass the following commands to it, in order to backslash-escape
+ # any special characters '\' and '"' that occur in %u:
+ # u=${1//\\/\\\\}
+ # u=${u//\"/\\\"}
+ # exec emacsclient --eval "(message-mailto \"$u\")"
+ # However, in the desktop entry '"', '\', and '$' must be escaped
# as '\\"', '\\\\', and '\\$', respectively. Yet another level of
# backslash escapes is needed for '\' and '$' in the here-document.
newmenu - emacsclient-mail.desktop <<-EOF
@@ -38,8 +42,11 @@ src_install() {
Type=Application
Name=Emacsclient (mail)
NoDisplay=true
- Exec=${EPREFIX}/bin/bash -c "exec ${EPREFIX}/usr/bin/emacsclient \
---eval \\\\"(message-mailto \\\\\\\\\\\\"\\\\\$1\\\\\\\\\\\\")\\\\"" bash %u
+ Exec=${EPREFIX}/bin/bash -c \
+"u=\\\\\${1//\\\\\\\\\\\\\\\\/\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\}; \
+u=\\\\\${u//\\\\\\\\\\\\"/\\\\\\\\\\\\\\\\\\\\\\\\\\\\"}; \
+exec ${EPREFIX}/usr/bin/emacsclient \
+--eval \\\\"(message-mailto \\\\\\\\\\\\"\\\\\$u\\\\\\\\\\\\")\\\\"" bash %u
Terminal=false
MimeType=x-scheme-handler/mailto;
EOF