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:42:03 +0100 [thread overview]
Message-ID: <87tvuhbw9w.fsf@gmail.com> (raw)
In-Reply-To: <87vaexbwxa.fsf@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 749 bytes --]
Actually the design issue is a bit deeper than that: As of now (even
with my suggested change) there is no proper way of retrieving the
browser name.
This can be problematic especially when it comes to managing processes
and frames (e.g. with EXWM).
So I suggest the following refactoring:
- Remove `browse-url-generic'.
- `browse-url-browser-function' should return a browser name (the function
might need a new name).
- `browse-url-default-browser' should obey the change and return a browser
name, with the first check being on `browse-url-generic-program`, second
check on the environment variable, third check on xdg-open, and the rest
as usual.
Everything gets simple, both the code and the user configuration, plus
it's more flexible.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
prev parent reply other threads:[~2018-02-16 0:42 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
2018-02-16 0:42 ` Pierre Neidhardt [this message]
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=87tvuhbw9w.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).