From mboxrd@z Thu Jan 1 00:00:00 1970 From: Charles Cave Subject: Looking for a sample function to find a location for org-capture Date: Thu, 12 Aug 2010 01:30:51 +0000 (UTC) Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=38805 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OjMdL-0005Kx-PC for emacs-orgmode@gnu.org; Wed, 11 Aug 2010 21:31:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OjMdK-0005fb-JY for emacs-orgmode@gnu.org; Wed, 11 Aug 2010 21:31:03 -0400 Received: from lo.gmane.org ([80.91.229.12]:40960) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OjMdK-0005fU-CQ for emacs-orgmode@gnu.org; Wed, 11 Aug 2010 21:31:02 -0400 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1OjMdH-0003KC-D4 for emacs-orgmode@gnu.org; Thu, 12 Aug 2010 03:30:59 +0200 Received: from 203.166.111.206 ([203.166.111.206]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 12 Aug 2010 03:30:59 +0200 Received: from charles_cave by 203.166.111.206 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 12 Aug 2010 03:30:59 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org I'm exploring the many features of org-capture and I see the documentation about a function for finding the location for refiling. I would like to see some sample code on how to do this. At the moment I am using a date tree to file my TODO items and notes. (I am writing an article about this and will publish soon) Let's say I had a headline structure for weeks of the year and I would like a function to add an item to the heading corresponding to the week of the year. Today (12th Aug) we are in Week 32. What would the function be to file under the appropriate heading: * 2010 ** 2010-Week-28 ** 2010-Week-29 ** 2010-Week-30 ** 2010-Week-31 ** 2010-Week-32 ** 2010-Week-33 Could the function create the heading if it didnt exist . just like org-capture handles creation of new brances on a date tree? Charles