Fix org-board-open-with advice
This commit is contained in:
parent
46ca98bd12
commit
b7bf077b7f
@ -1943,15 +1943,17 @@ Intelligently inserts an org-mode link from the clipboard.
|
||||
;; Use w3m instead of eww to open org-board archived links
|
||||
(advice-add 'org-board-open-with :around
|
||||
(lambda (oldfn filename-string arg &rest args)
|
||||
(if (and filename-string
|
||||
(cond
|
||||
((not (file-exists-p filename-string)) 1)
|
||||
((and filename-string
|
||||
(or (and arg (eq org-board-default-browser 'system))
|
||||
(and (not arg) (eq org-board-default-browser 'eww))))
|
||||
(let ((filename (concat "file://"
|
||||
(s-chop-prefix "file://"
|
||||
filename-string))))
|
||||
(w3m filename t)
|
||||
0)
|
||||
(apply oldfn filename-string arg args))))
|
||||
0))
|
||||
(:else (apply oldfn filename-string arg args)))))
|
||||
:general
|
||||
(org-mode-map "C-c b" org-board-keymap))
|
||||
#+END_SRC
|
||||
|
Loading…
Reference in New Issue
Block a user