I like to structure my org-mode projects using the :CATEGORY:
property, however categories seem not to be recognised by org-agenda-filter-by-regexp
(bound to =
). When viewing a rather large list of TODO items, it would be helpful to be able to narrow the list to matching categories.
I know that I can use org-agenda-filter-by-category
(<
), but this command must be executed on the category entry.
Is there a way to regexp filter the Org Agenda including categories?
The function below performs what I'd like, however I can't get it to work from the org-agenda
dispatcher as a custom agenda command.
(defun rnkn/org-category-match (str)
"Org Agenda match TODO headlines matching :CATEGORY: property STR."
(interactive "sCategory: ")
(org-tags-view t (concat "CATEGORY={" str "}")))
I'm using the following function to filter by category (solves the problem of
<
).I use (stu/show-agenda-and-todo) to make sure it filters every possible task, not only the ones shown in the buffer.
Type
M-x org-agenda RET m
and then enter the regex -- e.g.,PropertyDrawerName={regex}
Previous Answer (before the original poster edited the question) -- the current version of
org-element-property
/org-element-headline-parser
uses all UPPERCASE letters for the property drawer arguments: