emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Carsten Dominik <dominik@science.uva.nl>
To: Russell Adams <RLAdams@AdamsInfoServ.Com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Feature Request
Date: Tue, 26 Sep 2006 14:37:27 +0200	[thread overview]
Message-ID: <6b49125ddc270e8732b471029ab82eb5@science.uva.nl> (raw)
In-Reply-To: <20060925235852.GA32259@keroberos>


On Sep 26, 2006, at 1:58, Russell Adams wrote:

> I've gotten in a habit of storing my todo's in the following format,
> and I'm curious if there's a way to automate this...
>
> * Daily
> ** 2006-09
> *** 2006-09-25
> **** TODO Item One
>
> I don't always have an item for each day, its sparsely populated, but
> I'd like to automate making the first few headings.
>
> Any suggestions? Even a macro? ;]

The cl macro "loop" is your friend....

(defun my-date-tree (y1 y2)
   (interactive "nFirst year: \nnLast year: ")
   (require 'calendar)
   (loop for y from y1 to y2 do
     (message "Doing year %d..." y)
     (insert "* " (format "%4d" y) "\n")
     (loop for m from 1 to 12 do
       (insert "** " (format "%4d-%02d" y m) "\n")
       (loop for d from 1 to 31 do
         (when (= m (car
		    (calendar-gregorian-from-absolute
		     (calendar-absolute-from-gregorian
		      (list m d y)))))
           (insert "*** " (format "%4d-%02d-%02d" y m d) "\n"))))))

Hope this helps

- Carsten

  reply	other threads:[~2006-09-26 12:37 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-25 23:58 Feature Request Russell Adams
2006-09-26 12:37 ` Carsten Dominik [this message]
2006-09-27 15:09   ` Russell Adams
2007-02-08 16:05     ` Russell Adams
2007-02-08 16:46       ` Carsten Dominik
  -- strict thread matches above, loose matches on Subject: below --
2007-11-18 18:13 feature request Raimund Kohl-Füchsle
2007-11-19  3:14 ` Bastien
2009-03-23  2:14 Robert D. Crawford
2009-03-23  2:44 ` Matthew Lundin
2009-03-23 13:56   ` Robert D. Crawford
2009-03-23 11:24 ` Sebastian Rose
2009-03-24 16:53   ` Robert D. Crawford
2009-03-25 13:50     ` Charles Philip Chan
2009-03-25 14:51       ` Robert D. Crawford
2009-03-26  4:09 ` Carsten Dominik
2009-03-26 16:43   ` Robert D. Crawford
2010-10-10 13:50 Feature request David Abrahams
2010-10-10 15:43 ` Bernt Hansen
2010-10-10 18:03   ` David Abrahams
2010-10-10 16:30 ` Memnon Anon
2010-10-10 18:12 ` Juan Pechiar
2010-10-11  7:21 ` Carsten Dominik
2010-10-11 14:18   ` David Abrahams
2011-01-15 12:13   ` Bastien
2011-07-18 21:36 feature request Jude DaShiell
2011-07-18 23:13 ` Bastien
2011-07-19 12:10 ` MidLifeXis at PerlMonks
2013-06-25 15:22 42 147
2013-06-25 16:11 ` Christian Moe
2013-06-25 16:29   ` François Pinard
2013-06-25 18:31     ` Michael Brand
2021-01-14 17:01 Feature request Raoul Comninos
2021-01-17  5:30 ` Ihor Radchenko
2021-01-17  5:33   ` Raoul Comninos
2021-01-17  6:12     ` Ihor Radchenko
2021-01-17  6:18       ` Ihor Radchenko
2021-01-17  8:15         ` Raoul Comninos
2021-01-17  9:01           ` Ihor Radchenko
2021-01-17  9:20             ` Raoul Comninos
2021-01-18  2:17               ` Ihor Radchenko
2021-01-18  8:19                 ` Detlef Steuer
2021-01-18  1:46             ` Raoul Comninos
2021-01-18  2:19               ` Ihor Radchenko
2021-01-17  5:31 ` Ihor Radchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6b49125ddc270e8732b471029ab82eb5@science.uva.nl \
    --to=dominik@science.uva.nl \
    --cc=RLAdams@AdamsInfoServ.Com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).