ITADN

Cannot specify feeds via inherited tags

#99Openheraplem 创建于 2025-06-30
H
heraplemcommented
With `org-use-tag-inheritance` set to `t`, I expect elfeed-org to pick up the following feed: ``` #+title: feeds #+filetags: :elfeed: * [[https://www.haskellforall.com/feeds/posts/default][Haskell for all]] ``` But it does not. The problem is the following in `rmh-elfeed-org-import-trees`: ```elisp (member tree-id (org-element-property :tags h)) ``` In other words, it checks whether `tree-id` is among the tags *explicitly set at that headline*, rather than a tag that the headline "semantically" has. This could be fixed by using `org-get-tags`; e.g.: ```elisp (defun rmh-elfeed-org-import-trees (tree-id) "Get trees with \":ID:\" property or tag of value TREE-ID. Return trees with TREE-ID as the value of the id property or with a tag of the same value. Setting an \":ID:\" property is not recommended but I support it for backward compatibility of current users." (org-element-map (org-element-parse-buffer) 'headline (lambda (h) (when (or (member tree-id (org-get-tags h)) (equal tree-id (org-element-property :ID h))) h)))) ```
0 条评论