emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Possible to exclude/include tags for agenda custom commands?
@ 2020-02-12 19:03 Stig Brautaset
  2020-02-12 22:30 ` Bastien
  0 siblings, 1 reply; 18+ messages in thread
From: Stig Brautaset @ 2020-02-12 19:03 UTC (permalink / raw)
  To: emacs-orgmode


I use Org agenda to manage both work and non-work TODOs. I tend to use
the tags @home, @work. When at work I don't want to distractions from
@home stuff, and vice versa.

In a work context I would like an agenda view that excludes anything
tagged with @home, and a list of the 5 highest priority non-@home tasks.
Vice versa for a home context I want to exclude @work stuff. Items with
neither tag should show up in both views.

I can easily do this in the list of TODOs, with a tag search. However, I
haven't figured out how to do this for the agenda. Is it possible? If
so, how? If it's not possible, can I skip the agenda and instead create
a separate tags-todo search that shows a list of only those scheduled /
timestamped / deadlined for today in a separate stanza, so they stand
out from the unscheduled ones?

Here's what I'm currently using. The tags-todo search works as I like,
but I can't figure out how to exclude agenda items with certain tags
from the agendas.

(setq org-agenda-custom-commands
      '(("w" "Work Agenda"
	 ((agenda "" ((org-agenda-span 'day)))
	  (tags-todo "-@home-MAYBE/TODO"
		     ((org-agenda-max-entries 5)
		      (org-agenda-todo-ignore-scheduled 'all)
		      (org-agenda-todo-ignore-deadlines 'all)
		      (org-agenda-todo-ignore-timestamp 'all)))))
	("h" "Home Agenda"
	 ((agenda "")
	  (tags-todo "-@work-MAYBE/TODO"
		     ((org-agenda-max-entries 5)
		      (org-agenda-todo-ignore-scheduled 'all)
		      (org-agenda-todo-ignore-deadlines 'all)
		      (org-agenda-todo-ignore-timestamp 'all)))))
	("m" "Maybe"
	 ((tags-todo "MAYBE/PROJ")
	  (tags-todo "MAYBE-PROJ/TODO")))
	("P" "Projects" tags-todo "-MAYBE/PROJ")))
        
Stig

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2020-02-24 17:03 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-02-12 19:03 Possible to exclude/include tags for agenda custom commands? Stig Brautaset
2020-02-12 22:30 ` Bastien
2020-02-13 19:39   ` Stig Brautaset
2020-02-14 10:02     ` Bastien
2020-02-14 22:05     ` Adam Porter
2020-02-18 13:05       ` Bastien
2020-02-20  3:57         ` Adam Porter
2020-02-20  7:23           ` Bastien
2020-02-20 16:50     ` Eric Abrahamsen
2020-02-20 17:24       ` Bastien
2020-02-20 17:48         ` Eric Abrahamsen
2020-02-20 19:02           ` Eric Abrahamsen
2020-02-20 19:08             ` Bastien
2020-02-20 19:51               ` Eric Abrahamsen
2020-02-23 13:24                 ` Bastien
2020-02-23 20:55                   ` Eric Abrahamsen
2020-02-24  9:14                     ` Bastien
2020-02-24 17:03                       ` Eric Abrahamsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).