Laurynas Biveinis <laurynas.bivei...@gmail.com> writes: > I want to create a custom agenda view that filters by both TODO state > and tags, i.e. a combination of todo and tags-todo search types. I > have tried creating custom search action > ((org-agenda-todo "TODO") (org-agenda-filter "tag1|tag2")) but failed.
The easiest way is to do a simple search. 1. If you want just one tag, you can use: C-c a M TODO="TODO"+tag1 2. To find TODO *and* (tag1 *or* tag2): C-c a M TODO="TODO"+ALLTAGS={tag1\|tag2} 3. If you call this often, you can automate the search with a custom agenda command: (org-add-agenda-custom-command '("x" "TODO + tag1|tag2" tags-todo "TODO=\"TODO\"+ALLTAGS={tag1\\|tag2}")) Or you could use a block agenda: (org-add-agenda-custom-command '("x" "TODO + tag1|tag2" ((tags-todo "TODO=\"TODO\"+tag1") (tags-todo "TODO=\"TODO\"+tag2")))) See the following for more information: (info "(org) Matching tags and properties") http://orgmode.org/worg/org-tutorials/org-custom-agenda-commands.html http://orgmode.org/worg/org-tutorials/advanced-searching.html Best, Matt