Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Emacs org-mode scheduling an item multiple times a day?

Tags:

emacs

org-mode

I want to schedule a task in emacs org-mode to show up multiple times during the day.

Edit: as an example suppose I want yo call my wife every 2 hours during the day.

like image 260
drieddust Avatar asked Jan 08 '12 21:01

drieddust


2 Answers

In the absence of hour/minute level repeaters, if the interval is not too small, you might add multiple timestamps for the hours, while using the other facilities for repeated items:

** Testentry
<2012-01-19 Do 10:00 +1w>
<2012-01-19 Do 12:00 +1w>

The resulting agenda view

Thursday   19 January 2012
  Calendar:   10:00...... Testentry
  Calendar:   12:00...... Testentry

[...]

Thursday   26 January 2012
               8:00...... ----------------
  Calendar:    9:45-10:00 XXXXXXXXXXXXXX                        :OFFICE:
               10:00...... 
  Calendar:   10:00...... Testentry
              10:00...... ----------------
  Calendar:   12:00...... Testentry
[...]
like image 70
Tom Regner Avatar answered Nov 11 '22 13:11

Tom Regner


According to the Org Mode manual on Repeated Tasks there is an hourly repeater:

In the following example

** TODO Pay the rent
   DEADLINE: <2005-10-01 Sat +1m>

the +1m is a repeater; the intended interpretation is that the task has a deadline on <2005-10-01> and repeats itself every (one) month starting from that time. You can use yearly, monthly, weekly, daily and hourly repeat cookies by using the y/w/m/d/h letters.

You may use something like that:

* TODO Call Wife
  DEADLINE: <2013-02-17 Sun 16:00 +2h>

Unfortunately, I've noticed that special repeater modifiers (++ and .+) do not work properly for hourly repeaters. The manual says:

** TODO Call Father
   DEADLINE: <2008-02-10 Sun ++1w>
   Marking this DONE will shift the date by at least one week,
   but also by as many weeks as it takes to get this date into
   the future.  However, it stays on a Sunday, even if you called
   and marked it done on Saturday.

Based on this, you would expect that marking an entry with an hourly repeater (such as the one above) DONE would "shift time by at least n hours but also as many hours as it takes to get this date into the future".

However, here's what I got after marking both entries DONE:

** TODO Call Father
   DEADLINE: <2013-03-03 Sun ++1w>
   - State "DONE"       from "TODO"       [2013-02-25 Mon 23:06]
   :PROPERTIES:
   :LAST_REPEAT: [2013-02-25 Mon 23:06]
   :END:

** TODO Call Wife
   DEADLINE: <2013-02-17 Sun 18:00 ++2h>
   - State "DONE"       from "TODO"       [2013-02-25 Mon 23:06]
   :PROPERTIES:
   :LAST_REPEAT: [2013-02-25 Mon 23:06]
   :END:

As you can see, the time in the second entry has shifted to 18:00, but the date is still the same.


Concerning an approach for creating repeating items explicitly another feature could be useful. The manual says:

An alternative to using a repeater is to create a number of copies of a task subtree, with dates shifted in each copy. The command C-c C-x c was created for this purpose, it is described in Structure editing.

But unfortunately, it doesn't work with hours.


Information in this post based on Org Mode version 7.9.3.e.

like image 31
Serhiy Demydenko Avatar answered Nov 11 '22 11:11

Serhiy Demydenko