emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/kiwix e2933785 174/192: add autoload cookie for kiwix.e


From: Stefan Monnier
Subject: [elpa] externals/kiwix e2933785 174/192: add autoload cookie for kiwix.el Org link functions
Date: Sat, 19 Dec 2020 00:41:55 -0500 (EST)

branch: externals/kiwix
commit e293378588575cb2781facac4ce8d745cd7de58e
Author: stardiviner <numbchild@gmail.com>
Commit: stardiviner <numbchild@gmail.com>

    add autoload cookie for kiwix.el Org link functions
---
 kiwix.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/kiwix.el b/kiwix.el
index 36db1a5..4794e78 100644
--- a/kiwix.el
+++ b/kiwix.el
@@ -347,7 +347,7 @@ for query string and library interactively."
     ;; validate query is non-English
     (kiwix-select-library "zh")))
 
-
+;;;###autoload
 (defun org-wikipedia-link-open (link)
   "Open LINK in external Wikipedia program."
   ;; The regexp: (library):query
@@ -370,6 +370,7 @@ for query string and library interactively."
       ;; (prin1 (format "library: %s, query: %s, url: %s" library query url))
       (browse-url url))))
 
+;;;###autoload
 (defun org-wikipedia-link-export (link description format)
   "Export the Wikipedia LINK with DESCRIPTION for FORMAT from Org files."
   (when (string-match "\\(?:(\\(.*\\)):\\)?\\([^] \n\t\r]*\\)" link)
@@ -386,6 +387,7 @@ for query string and library interactively."
          ((eq format 'latex) (format "\\href{%s}{%s}" path desc))
          (t path))))))
 
+;;;###autoload
 (defun org-wikipedia-store-link ()
   "Store a link to a Wikipedia link."
   ;; [C-c o C-l l] `org-store-link'
@@ -399,11 +401,13 @@ for query string and library interactively."
                             :description query)
       link)))
 
+;;;###autoload
 (org-link-set-parameters "wikipedia" ; NOTE: use `wikipedia' for future 
backend changing.
                          :follow #'org-wikipedia-link-open
                          :store #'org-wikipedia-store-link
                          :export #'org-wikipedia-link-export)
 
+;;;###autoload
 (add-hook 'org-store-link-functions 'org-wikipedia-store-link t)
 
 (defun kiwix-mode-enable ()



reply via email to

[Prev in Thread] Current Thread [Next in Thread]