[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/kiwix 2d33910 072/192: Merge tag 'v0.5.0' into develop
From: |
Stefan Monnier |
Subject: |
[elpa] externals/kiwix 2d33910 072/192: Merge tag 'v0.5.0' into develop |
Date: |
Sat, 19 Dec 2020 00:41:36 -0500 (EST) |
branch: externals/kiwix
commit 2d33910df0897903c126c2eb06526d8323a4159b
Merge: f84b449 3485131
Author: stardiviner <numbchild@gmail.com>
Commit: stardiviner <numbchild@gmail.com>
Merge tag 'v0.5.0' into develop
Support Org-mode 9.0
---
README.org | 6 ++++++
kiwix.el | 14 ++++++++++----
2 files changed, 16 insertions(+), 4 deletions(-)
diff --git a/README.org b/README.org
index f76677b..a7824e5 100644
--- a/README.org
+++ b/README.org
@@ -78,3 +78,9 @@ The link format is like this:
#+END_EXAMPLE
The =(library)= can be =wikipedia_en=, =wikipedia_zh=, =wiktionary_en=, or
=en=, =zh= etc.
+
+* Test
+
+- [[wiki:Operations%20Research][Operations Research]] :: query contains space.
+- [[wiki:Operations%20research][Operations research]] :: the second word is
not capitalized.
+- [[wiki:%E4%B8%AD%E5%9B%BD][中国]] :: non-english query
diff --git a/kiwix.el b/kiwix.el
index 3dd7c1a..4636c9b 100644
--- a/kiwix.el
+++ b/kiwix.el
@@ -229,11 +229,17 @@ for query string and library interactively."
(defun org-wiki-link-open (link)
"Open LINK in external wiki program."
- (when (string-match "\\(?:(\\(.*\\)):\\)?\\([^] \n\t\r]*\\)" link) ;
(library):query
+ ;; The regexp: (library):query
+ ;; - query : should not exclude space
+ (when (string-match "\\(?:(\\(.*\\)):\\)?\\([^]\n\t\r]*\\)" link) ;
(library):query
(let* (
- ;; convert between libraries full name and abbrev.
- (library (kiwix-get-library-fullname (or (match-string 1 link)
- "default")))
+ (library (if (string-match-p "[a-zA-Z\ ]+" (match-string 2 link)) ;
validate query is English
+ ;; convert between libraries full name and abbrev.
+ (kiwix-get-library-fullname (or (match-string 1 link)
+ "default"))
+ ;; validate query is non-English
+ (kiwix-get-library-fullname "zh")
+ ))
(query (match-string 2 link))
(url (concat
kiwix-server-url
- [elpa] externals/kiwix 3fe879f 168/192: refresh libraries before selecting library, (continued)
- [elpa] externals/kiwix 3fe879f 168/192: refresh libraries before selecting library, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 716c5f6 169/192: Docker container launch command use library.xml index file, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix cd95bc9 171/192: update README: using libraries index file "library.xml", Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 9db0a13 172/192: display screenshots at beginning, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 5f64044 175/192: support detect whether query is chinese, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 6c6c443 176/192: fix Org link open function, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 7fda411 184/192: fix org-link-set-parameters functions not available when Org not loaded, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 5bd84a6 187/192: select kiwix library when completing org link, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix d92a371 189/192: Fix some byte-compile warnings, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 905a413 192/192: Fix #4 add GNU license info in package source code file, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 2d33910 072/192: Merge tag 'v0.5.0' into develop,
Stefan Monnier <=
- [elpa] externals/kiwix bf128fb 087/192: Merge branch 'hotfix/void-function_org-link-set-parameters', Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix f3a2d8f 091/192: Merge branch 'release/0.6.1', Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix f84b449 070/192: autoload Org-mode link adding, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 3485131 071/192: Merge branch 'develop', Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 21b5dfe 073/192: fix variable invalid for autoload kiwix, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix f86cb0d 075/192: Merge tag 'v0.5.1' into develop, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 33d6608 076/192: org-mode wiki: link store function solved., Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 9d16244 082/192: Merge tag 'v0.5.2' into develop, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix 72aadb4 084/192: Merge tag 'v0.6.0' into develop, Stefan Monnier, 2020/12/19
- [elpa] externals/kiwix cc86dc7 085/192: load for `org-link-set-parameters', Stefan Monnier, 2020/12/19