From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Barton Subject: Re: Alternate format for datetree Date: Wed, 29 Aug 2012 08:49:08 +0100 Message-ID: <503DC974.7030508@manor-farm.org> References: <20532.1346040247@alphaville> <503C861B.2040002@wilkesley.net> <6796.1346158256@alphaville> Reply-To: ian@manor-farm.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([208.118.235.92]:49192) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T6d4L-0005kr-VU for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 03:52:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T6d4F-0002c5-Vi for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 03:52:09 -0400 Received: from mail2.wilkesley.net ([109.74.196.44]:44093 helo=li40-130.members.linode.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T6d4F-0002Vd-Pj for emacs-orgmode@gnu.org; Wed, 29 Aug 2012 03:52:03 -0400 Received: from [192.168.1.2] (86-46-50-120-dynamic.b-ras3.mvw.galway.eircom.net [86.46.50.120]) (Authenticated sender: ian@wilkesley.net) by li40-130.members.linode.com (Postfix) with ESMTPSA id AC7A45C17AE for ; Wed, 29 Aug 2012 08:51:48 +0100 (BST) In-Reply-To: <6796.1346158256@alphaville> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org On 28/08/12 13:50, Nick Dokos wrote: > Ian Barton wrote: > >> I would like to use something like this. However, using a recent git >> checkout of org mode and the following simple template from the >> original list message: >> >> ("u" >> "Test" >> entry >> (file+headline "~/test.org" >> ,(format "%s %s" >> (format-time-string "%B") >> (format-time-string "%Y")))) >> I get the following error: >> >> Debugger entered--Lisp error: (wrong-type-argument stringp (\, (format >> "%s %s" (format-time-string "%B") (format-time-string "%Y")))) >> regexp-quote((\, (format "%s %s" (format-time-string "%B") >> (format-time-string "%Y")))) >> org-capture-set-target-location() >> org-capture(nil) >> call-interactively(org-capture nil nil) >> >> I also get the same error from John Hendy's template. Is this a bug in >> recent versions of org, or is there an error in the template lisp? I >> have tried doing a git bisect, but can only go back a few commits, as >> my config now includes several things that have only recently been >> added to org. >> > > You are missing the backquote: > > --8<---------------cut here---------------start------------->8--- > `("u" > "Test" > entry > (file+headline "~/test.org" > ,(format "%s %s" > (format-time-string "%B") > (format-time-string "%Y")))) > --8<---------------cut here---------------end--------------->8--- > > Nick > Thanks Nick. Hwever with the following minimal template, from the OP, I still get the error: ;; org-capture settings. (setq org-capture-templates `(("t" "test" entry (file+headline "~/file.org" ,(format "%s" (format-time-string "%m"))) ,(format "** %s \n*** %s-%s \n**** [%s-%s-%s %s %s:%s] " (format-time-string "%d") (format-time-string "%Y") (format-time-string "%A") (format-time-string "%Y") (format-time-string "%m") (format-time-string "%d") (format-time-string "%a") (format-time-string "%H") (format-time-string "%M")) ))) Ian.