From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Sullivan, Gregory (US SSA)" Subject: RE: using (id "Name") target in org-capture-templates Date: Sun, 27 Feb 2011 20:38:00 -0500 Message-ID: References: <87wrklprxg.fsf@altern.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=35144 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pts3u-00062r-M9 for Emacs-orgmode@gnu.org; Sun, 27 Feb 2011 20:38:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pts3p-0008QM-Gy for Emacs-orgmode@gnu.org; Sun, 27 Feb 2011 20:38:10 -0500 Received: from dmzms99902.na.baesystems.com ([149.32.200.66]:40821) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pts3p-0008QB-F2 for Emacs-orgmode@gnu.org; Sun, 27 Feb 2011 20:38:05 -0500 In-Reply-To: <87wrklprxg.fsf@altern.org> Content-Language: en-US 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: Bastien Cc: "Emacs-orgmode@gnu.org" The way I understood your patch is that I can use (currentfile) as _the_ ta= rget expression in a capture template. What I was requesting was to use 'c= apturefile' _within_ a file+headline target expressions. Let me re-include = a motivating example - as your citation didn't include it: (setq org-capture-templates '(("j" "Journal" entry (file+headline currentfile "Journal") "* %a\n\n%i= ")) ("t" "To Do" entry (file+headline currentfile "Tasks") "* TODO %? %i\n= "))) which does not seem to be implemented in the current git version, unless I'= ve completely messed up my orgmode git checkout. Possibly this could be done by checking for the symbol 'currentfile in org-= capture-target-buffer, and using (buffer-file-name). Do you think that would work? Thanks again. -- Greg --=20 Greg Sullivan gregory.sullivan@baesystems.com (781)262-4553 (office) (978)430-3461 (cell) -----Original Message----- From: Bastien Guerry [mailto:bastienguerry@googlemail.com] On Behalf Of Bas= tien Sent: Sunday, February 27, 2011 6:37 AM To: Sullivan, Gregory (US SSA) Cc: Giovanni Ridolfi; Emacs-orgmode@gnu.org Subject: Re: [Orgmode] using (id "Name") target in org-capture-templates Hi Gregory, "Sullivan, Gregory (US SSA)" writes: > It would be quite useful if I could use currentfile in place of > "path/to/file" in the various Target patterns. That is, it would be > nice to write something like: This is already implemented in Org's git version. See the email you're replying to, I gave the explanations. Thanks, --=20 Bastien