Artikelformat

Code snippet for S05E04 video

Yesterday I posted the E05S04 tutorial video where I showed a custom view that has tasks tagged with URGENT together with tasks tagged with PHONE and then an agenda for the day. In the comments I was asked how to do such a view. So here is the code:

The code has to go to your „~/.emacs“ file or whatever file you use for initializing the orgmode customization (I use a „org-global.el“ for that which is stored in the cloud and synchronized to all PCs where I use OrgMode).

This is the start of my example customization file. If you put it in your file locate that line with „custom-set-variables“ and inside that the „org-agenda-custom-commands“ list. After the last line the code for other custom agenda views goes on, so if you want to paste it into your file take the lines 9 to 29 and paste it to your org-agenda-custom-commands structure in the initialization file.

The „D“ in line 9 defines the key for that custom view together with the explanation. Then you get two views with „tags-todo“ one that selects the „URGENT“ tag, the other one that selects for items tagged with „PHONE“. Both sections get headlines.

Orgmode day viewIn line 20 the agenda view for the current day starts. To avoid that we get an agenda with more than 1 day the setting „org-agenda-span“ is set to 1 (one day). I limited the view to 2 „org-agenda-files“, so you can select which of your org files will be searched to create that view. The setting „org-agenda-sorting-strategy“ has 2 entries „time-up“ to ensure that the first thing you see in your agenda is a sort of mini-daily timeline. The „priority-down“ setting makes sure that the tasks with the highest priority ends up on top of this list. So as an example the daily view looks like the picture on the right side (click to enlarge).  This is like a quick „dashboard“ that shows all the important entries for today. I use that view when I create my daily plan every morning. Of course you can advance the agenda view of today by using the usual navigation keys („f“ for forward one day, „b“ for back one day) to see other days.

1 Star2 Stars3 Stars4 Stars5 Stars (Noch nicht bewertet)

Loading...

 

Autor: Rainer

Diplom-Informatiker, Baujahr 1961, Vater von 2 Kindern, Hundehalter, Sportschütze und Vereinsvorstand, Hobbymusiker (mit zweifelhaftem Erfolg), politisch interessiert, Leseratte, Freizeit-Philosoph und letztlich Blogger.

Kommentare sind geschlossen.