1
0
Fork 0

[oni-org] Use ‘rx’ instead of ‘rx-to-string’

‘rx’ should expand to what is needed to make sure that the right thing is done.
I feel more comfortable using this than ‘rx-to-string’ while unquoting the
variables I use.
This commit is contained in:
Tom Willemse 2022-05-11 20:37:11 -07:00
parent 54e9c9c26f
commit 4b94f8403c

View file

@ -4,7 +4,7 @@
;; Author: Tom Willemse <tom@ryuslash.org>
;; Keywords: local
;; Version: 2022.0424.025154
;; Version: 2022.0508.160831
;; Package-Requires: (oni-yasnippet oni-alert oni-hydra org org-contrib org-bullets org-edna diminish all-the-icons olivetti mixed-pitch)
;; This program is free software; you can redistribute it and/or modify
@ -842,8 +842,10 @@ This is an around advice for org-html--svg-image as FUN."
(when (not (null current-heading-id))
(save-excursion
(goto-char (point-min))
(while (re-search-forward (rx-to-string `(or (seq "[[id:" ,current-heading-id "]")
(seq "#" ,current-heading-id "]"))) nil t)
(while (re-search-forward
(rx (or (seq "[[id:" (literal current-heading-id) "]")
(seq "#" (literal current-heading-id) "]")))
nil t)
(unless (or (oni-org-in-dblock-p)
(oni-org-at-origin-property-p))
(let ((components (org-heading-components)))