emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Repeat every X business days and every Xth day-of-the-week
@ 2012-03-18  5:38 Jay McCarthy
  2012-03-18  6:29 ` Nick Dokos
  2012-03-18 13:31 ` Bernt Hansen
  0 siblings, 2 replies; 4+ messages in thread
From: Jay McCarthy @ 2012-03-18  5:38 UTC (permalink / raw)
  To: emacs-orgmode

Dear org-mode developers,

I wish that I could write +1bd on a repeating tasks so that it skips
from Friday to Monday.

I looked into implementing this myself, but there are a lot of places
(29) where the regexp [dwmy] is used and it scares me off because I
think I'll break something. It almost seems like you should be able to
add a new 'what' to 'org-timestamp-change' and it will Just Work. But
the algorithm in there would need to change a bit, because it would
try to change by a number of days, but then adjust based on the advic
day of the week.

For now, I just manually complete the task on Saturdays and Sundays...
but it seems wrong to get credit in the TODO -> DONE log when I really
didn't do it :)

I also wish that I could specify in some way that an event happens
every third Thursday of the month or on the first and third Wednesdays
(when my recycling cans are picked up). I don't know of a good way to
fit that into the current annotation scheme of + and ++.

If you have any advice about how I could do it myself safely, I'd be
happy to try and contribute.

Jay

-- 
Jay McCarthy <jay@cs.byu.edu>
Assistant Professor / Brigham Young University
http://faculty.cs.byu.edu/~jay

"The glory of God is Intelligence" - D&C 93

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

* Re: Repeat every X business days and every Xth day-of-the-week
  2012-03-18  5:38 Repeat every X business days and every Xth day-of-the-week Jay McCarthy
@ 2012-03-18  6:29 ` Nick Dokos
  2012-03-18 13:30   ` Bernt Hansen
  2012-03-18 13:31 ` Bernt Hansen
  1 sibling, 1 reply; 4+ messages in thread
From: Nick Dokos @ 2012-03-18  6:29 UTC (permalink / raw)
  To: Jay McCarthy; +Cc: nicholas.dokos, emacs-orgmode

Jay McCarthy <jay.mccarthy@gmail.com> wrote:

> ... 
> I also wish that I could specify in some way that an event happens
> every third Thursday of the month or on the first and third Wednesdays
> (when my recycling cans are picked up). I don't know of a good way to
> fit that into the current annotation scheme of + and ++.
> 
> If you have any advice about how I could do it myself safely, I'd be
> happy to try and contribute.

Diary s-exprs can do things like this:

--8<---------------cut here---------------start------------->8---

* TODO every third Thursday of the month
  <%%(org-float t 4 3)>

* TODO every first and third Wednesday of the month
  <%%(or (org-float t 3 1) (org-float t 3 3))>
--8<---------------cut here---------------end--------------->8---

See
	(info "(org) Timestamps")
	(info "(emacs) Special Diary entries")

Nick

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

* Re: Repeat every X business days and every Xth day-of-the-week
  2012-03-18  6:29 ` Nick Dokos
@ 2012-03-18 13:30   ` Bernt Hansen
  0 siblings, 0 replies; 4+ messages in thread
From: Bernt Hansen @ 2012-03-18 13:30 UTC (permalink / raw)
  To: nicholas.dokos; +Cc: Jay McCarthy, emacs-orgmode

Nick Dokos <nicholas.dokos@hp.com> writes:

> Jay McCarthy <jay.mccarthy@gmail.com> wrote:
>
>> ... 
>> I also wish that I could specify in some way that an event happens
>> every third Thursday of the month or on the first and third Wednesdays
>> (when my recycling cans are picked up). I don't know of a good way to
>> fit that into the current annotation scheme of + and ++.
>> 
>> If you have any advice about how I could do it myself safely, I'd be
>> happy to try and contribute.
>
> Diary s-exprs can do things like this:
>
>
> * TODO every third Thursday of the month
>   <%%(org-float t 4 3)>
>
> * TODO every first and third Wednesday of the month
>   <%%(or (org-float t 3 1) (org-float t 3 3))>

Except these TODO's don't behave like repeating tasks.  If you mark it
DONE it stays DONE as opposed to cycling back to TODO for the next
occurrence.

Regards,
Bernt

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

* Re: Repeat every X business days and every Xth day-of-the-week
  2012-03-18  5:38 Repeat every X business days and every Xth day-of-the-week Jay McCarthy
  2012-03-18  6:29 ` Nick Dokos
@ 2012-03-18 13:31 ` Bernt Hansen
  1 sibling, 0 replies; 4+ messages in thread
From: Bernt Hansen @ 2012-03-18 13:31 UTC (permalink / raw)
  To: Jay McCarthy; +Cc: emacs-orgmode

Jay McCarthy <jay.mccarthy@gmail.com> writes:

> I wish that I could write +1bd on a repeating tasks so that it skips
> from Friday to Monday.
>
> I looked into implementing this myself, but there are a lot of places
> (29) where the regexp [dwmy] is used and it scares me off because I
> think I'll break something. It almost seems like you should be able to
> add a new 'what' to 'org-timestamp-change' and it will Just Work. But
> the algorithm in there would need to change a bit, because it would
> try to change by a number of days, but then adjust based on the advic
> day of the week.
>
> For now, I just manually complete the task on Saturdays and Sundays...
> but it seems wrong to get credit in the TODO -> DONE log when I really
> didn't do it :)

You can also just adjust the date with S-right until the next
occurrence - this doesn't mark it DONE.  Then you don't get 'credit' for
doing it on weekends.

HTH,
Bernt

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

end of thread, other threads:[~2012-03-18 13:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-18  5:38 Repeat every X business days and every Xth day-of-the-week Jay McCarthy
2012-03-18  6:29 ` Nick Dokos
2012-03-18 13:30   ` Bernt Hansen
2012-03-18 13:31 ` Bernt Hansen

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).