From: Pierre Neidhardt <ambrevar@gmail.com>
To: Noam Postavsky <npostavs@gmail.com>
Cc: 18986@debbugs.gnu.org
Subject: bug#18986: #18986 Design bug in browse-url.el: browse-url-can-use-xdg-open's logic uses overly strict assumption
Date: Fri, 16 Feb 2018 01:28:01 +0100 [thread overview]
Message-ID: <87vaexbwxa.fsf@gmail.com> (raw)
In-Reply-To: <871shn80et.fsf@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 625 bytes --]
OK, I'm running Emacs 26 now, and it the xdg-open is indeed solved as per #25778.
Still one rough edge left: if xdg-open is missing but BROWSER is set,
Emacs will not run the browser configured by the user but the first one
it found in the list.
I think the patch I suggested above would be good enough, or maybe even better:
(defun browse-url-default-browser (url &rest args)
...
(apply
(cond
...
+ ((and (getenv "BROWSER") (executable-find (getenv "BROWSER")))
+ (executable-find (getenv "BROWSER")))
((memq system-type '(windows-nt ms-dos cygwin))
'browse-url-default-windows-browser)
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
next prev parent reply other threads:[~2018-02-16 0:28 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-07 11:04 Design bug in browse-url.el: browse-url-can-use-xdg-open's logic uses overly strict assumption Florian v. Savigny
2014-11-08 17:19 ` bug#18986: " Jan D.
[not found] ` <E1A681AD-2DC5-4143-B7ED-F179A8856D6B@swipnet.se>
2014-11-08 18:05 ` Stefan Monnier
2014-11-15 12:31 ` Florian v. Savigny
2018-02-12 16:23 ` bug#18986: #18986 " Pierre Neidhardt
2018-02-12 17:47 ` Eli Zaretskii
2018-02-12 17:51 ` Pierre Neidhardt
2018-02-12 18:42 ` Eli Zaretskii
2018-02-14 21:46 ` Pierre Neidhardt
2018-02-15 2:14 ` Noam Postavsky
2018-02-16 0:28 ` Pierre Neidhardt [this message]
2018-02-16 0:42 ` Pierre Neidhardt
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87vaexbwxa.fsf@gmail.com \
--to=ambrevar@gmail.com \
--cc=18986@debbugs.gnu.org \
--cc=npostavs@gmail.com \
/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 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).