summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Stephani <phst@google.com>2016-10-09 16:55:04 +0200
committerJonas Bernoulli <jonas@bernoul.li>2016-10-09 18:17:36 +0200
commitaaaeb98c022d0cd91a582f25d299ab4d0607596a (patch)
treeea154a98a98b4dc5b271c182886409a6cb8ac381
parent19201be2c59a7762da97835f7efc11f86191b676 (diff)
prefer debianized binary name, if available
On debianized Emacsen, emacsclient is installed as /usr/bin/emacsclient.FLAVOR. Prefer that file name if possible, as it’s likely to be the most accurate.
-rw-r--r--with-editor.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/with-editor.el b/with-editor.el
index 467fb63..546c119 100644
--- a/with-editor.el
+++ b/with-editor.el
@@ -125,7 +125,9 @@ please see https://github.com/magit/magit/wiki/Emacsclient."))
"emacsclient" path
(cl-mapcan
(lambda (v) (cl-mapcar (lambda (e) (concat v e)) exec-suffixes))
- (nconc (cl-mapcon (lambda (v)
+ (nconc (and (boundp 'debian-emacs-flavor)
+ (list (format ".%s" debian-emacs-flavor)))
+ (cl-mapcon (lambda (v)
(setq v (mapconcat #'identity (reverse v) "."))
(list v (concat "-" v) (concat ".emacs" v)))
(reverse version-lst))