diff options
-rw-r--r-- | init.el | 2 | ||||
-rw-r--r-- | lisp/+org.el | 10 |
2 files changed, 12 insertions, 0 deletions
diff --git a/init.el b/init.el index 4eb8cdd..4438393 100644 --- a/init.el +++ b/init.el | |||
@@ -490,6 +490,8 @@ | |||
490 | "|" "DONE(d!)") | 490 | "|" "DONE(d!)") |
491 | (sequence "|" "CANCELED(k!)") | 491 | (sequence "|" "CANCELED(k!)") |
492 | (sequence "MEETING(m)"))) | 492 | (sequence "MEETING(m)"))) |
493 | (setf (alist-get "\\.x?html?\\'" org-file-apps nil nil #'equal) | ||
494 | #'+org-open-html) | ||
493 | (:bind "RET" #'+org-return-dwim | 495 | (:bind "RET" #'+org-return-dwim |
494 | "<S-return>" #'+org-table-copy-down | 496 | "<S-return>" #'+org-table-copy-down |
495 | "C-c C-l" #'+org-insert-link-dwim | 497 | "C-c C-l" #'+org-insert-link-dwim |
diff --git a/lisp/+org.el b/lisp/+org.el index 348ba6e..5869622 100644 --- a/lisp/+org.el +++ b/lisp/+org.el | |||
@@ -442,5 +442,15 @@ the deletion might narrow the column." | |||
442 | (org-up-heading-all 1)) | 442 | (org-up-heading-all 1)) |
443 | (org-open-at-point arg))))) | 443 | (org-open-at-point arg))))) |
444 | 444 | ||
445 | ;;; Open local HTML files with `browse-url' | ||
446 | |||
447 | (defun +org-open-html (file-path link-string) | ||
448 | "Open FILE-PATH with `browse-url'. | ||
449 | This function is intended to use with `org-file-apps'. See the | ||
450 | documentation of that function for a description of the two | ||
451 | arguments here, FILE-PATH and LINK-STRING." | ||
452 | (message "Opening %s (%s)..." file-path link-string) | ||
453 | (browse-url file-path)) | ||
454 | |||
445 | (provide '+org) | 455 | (provide '+org) |
446 | ;;; +org.el ends here | 456 | ;;; +org.el ends here |