Fix: (link) Save excursion around regexp search
Fixes #279. Thanks to Marc Fargas (@telenieko) for reporting. Released as 0.6.2.
This commit is contained in:
parent
f666fe150f
commit
991906c183
3 changed files with 272 additions and 252 deletions
|
|
@ -522,6 +522,11 @@ Simple links may also be written manually in either sexp or non-sexp form, like:
|
|||
|
||||
/Note:/ Breaking changes may be made before version 1.0, but in the event of major changes, attempts at backward compatibility will be made with obsolescence declarations, translation of arguments, etc. Users who need stability guarantees before 1.0 may choose to use tagged stable releases.
|
||||
|
||||
** 0.6.2
|
||||
|
||||
*Fixed*
|
||||
+ ~link~ predicate when used in an ~or~'ed query. ([[https://github.com/alphapapa/org-ql/issues/279][#279]]. Thanks to [[https://github.com/telenieko][Marc Fargas]] for reporting.)
|
||||
|
||||
** 0.6.1
|
||||
|
||||
*Fixed*
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
;; Author: Adam Porter <adam@alphapapa.net>
|
||||
;; Url: https://github.com/alphapapa/org-ql
|
||||
;; Version: 0.6.1
|
||||
;; Version: 0.6.2
|
||||
;; Package-Requires: ((emacs "26.1") (dash "2.18.1") (f "0.17.2") (map "2.1") (org "9.0") (org-super-agenda "1.2") (ov "1.0.6") (peg "1.0") (s "1.12.0") (transient "0.1") (ts "0.2-pre"))
|
||||
;; Keywords: hypermedia, outlines, Org, agenda
|
||||
|
||||
|
|
@ -1461,7 +1461,8 @@ any link is found."
|
|||
(setf description (regexp-quote description)))
|
||||
(when target
|
||||
(setf target (regexp-quote target))))
|
||||
(when (re-search-forward org-ql-link-regexp (org-entry-end-position) t)
|
||||
(when (save-excursion
|
||||
(re-search-forward org-ql-link-regexp (org-entry-end-position) t))
|
||||
(pcase description-or-target
|
||||
('nil (and (or (null target)
|
||||
(string-match-p target (match-string 1)))
|
||||
|
|
|
|||
510
org-ql.info
510
org-ql.info
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue