summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2021-04-08 17:16:56 +0100
committerjao <jao@gnu.org>2021-04-08 17:16:56 +0100
commit7b3614ff92ef8cb8dc18b5e5bfb798dc9e98288a (patch)
tree46567083831b4ac1c53d94af928be14941d0f8f8
parent3512562be70369611bd6e3ac796d17297a6c38a7 (diff)
downloadelibs-7b3614ff92ef8cb8dc18b5e5bfb798dc9e98288a.tar.gz
elibs-7b3614ff92ef8cb8dc18b5e5bfb798dc9e98288a.tar.bz2
properly open html files with eww
-rw-r--r--eww.org4
1 files changed, 3 insertions, 1 deletions
diff --git a/eww.org b/eww.org
index 031eba4..5ce22e0 100644
--- a/eww.org
+++ b/eww.org
@@ -12,7 +12,9 @@
(string= ,url
(url-encode-url (eww-current-url)))))
(jao-eww-session--list-buffers))))
- (if bf (switch-to-buffer bf) (eww url 4))))
+ (cond (bf (switch-to-buffer bf))
+ ((string-match-p url "^file://") (eww-open-file url))
+ (t (eww url 4)))))
(setq jao-browse-url-function #'jao-eww-browse-url)
(setq browse-url-browser-function jao-browse-url-function)