emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Russell Adams <RLAdams@AdamsInfoServ.Com>
To: emacs-orgmode@gnu.org
Subject: Re: Feature Request
Date: Thu, 8 Feb 2007 10:05:49 -0600	[thread overview]
Message-ID: <20070208160549.GB16624@odin.demosthenes.org> (raw)
In-Reply-To: <20060927150921.GB17927@keroberos>

I started tinkering, this being my first macro.

I can't say its behaving as I expected.

(defun my-daily-insertion
  (interactive)
  (beginning-of-buffer)
  (re-search-forward "DAILY-INSERTION-POINT")
  (forward-line -1)
  (insert "*** " (format-time-string "%Y%m%d" (current-time)) )
)

I'd welcome input.

Russell

On Wed, Sep 27, 2006 at 10:09:21AM -0500, Russell Adams wrote:
> The way I'm reading that macro, it'll prompt me for a date, etc. That
> would be useful for creating a range of dates in a tree if I needed to
> define a time period.
> 
> I guess I didn't explain myself clearly. I wanted to generate those
> dated headings under the "Daily" heading for the current date
> only. Just a shortcut so I can hit a single key to add todo items for
> today, and have them added to my chronological "Daily" tree.
> 
> I've just found that I'm managing TODO and agenda scheduled items
> well, but I didn't have a good way to handle all the little
> miscellaneous items that pop up. No reason to spend time filing them
> elsewhere, just a date would suffice. It also helps keep the tree
> sparse when searching.
> 
> Russell
> 
> On Tue, Sep 26, 2006 at 02:37:27PM +0200, Carsten Dominik wrote:
> > 
> > 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
> > 
> ------------------------------------------------------------------
> Russell Adams                            RLAdams@AdamsInfoServ.com
> 
> PGP Key ID:     0x1160DCB3           http://www.adamsinfoserv.com/
> 
> Fingerprint:    1723 D8CA 4280 1EC9 557F  66E8 1154 E018 1160 DCB3
> 
> 
> _______________________________________________
> Emacs-orgmode mailing list
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
------------------------------------------------------------------
Russell Adams                            RLAdams@AdamsInfoServ.com

PGP Key ID:     0x1160DCB3           http://www.adamsinfoserv.com/

Fingerprint:    1723 D8CA 4280 1EC9 557F  66E8 1154 E018 1160 DCB3

  reply	other threads:[~2007-02-08 16:06 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
2006-09-27 15:09   ` Russell Adams
2007-02-08 16:05     ` Russell Adams [this message]
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=20070208160549.GB16624@odin.demosthenes.org \
    --to=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).