emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <ndokos@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: Capture with org-directory not working?
Date: Mon, 19 Sep 2016 11:47:36 -0400	[thread overview]
Message-ID: <87vaxr51t3.fsf@gmail.com> (raw)
In-Reply-To: m2h99cc88l.fsf@krugs.de

Rainer M Krug <Rainer@krugs.de> writes:

> Hi
>
> I have the following capture template:
>
> ,----
> |   ("T"   "TODO to be logged in notes.org"    
> |    entry   (file+headline (concat org-directory "/notes.org") "Tasks")        
> |    ;; entry   (file+headline "~/org/notes.org" "Tasks")        
> |    "* TODO [#D] \n%i \n:PROPERTIES: \n:END: \n%? \n%a")
> `----
>
> As it is now, it is not working, but when I use the secont=d entry line,
> it is working.
>

Try (!!note the backquote at the beginning  and the comma before the concat form!!):

--8<---------------cut here---------------start------------->8---
(setq org-capture-templates
 `(
   ...
   ("T"   "TODO to be logged in notes.org"    
    entry   (file+headline ,(concat org-directory "/notes.org") "Tasks")        
    "* TODO [#D] \n%i \n:PROPERTIES: \n:END: \n%? \n%a")
   ...))
--8<---------------cut here---------------end--------------->8---


See

  (info "(elisp) Backquote")


-- 
Nick

  reply	other threads:[~2016-09-19 15:48 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-19 13:46 Capture with org-directory not working? Rainer M Krug
2016-09-19 15:47 ` Nick Dokos [this message]
2016-09-20  7:25   ` Rainer M Krug
2016-09-20 15:00     ` Adam Porter
2016-09-20 16:03       ` Rainer Krug
2016-09-20 17:08         ` Adam Porter
2016-09-21  7:05           ` Rainer Krug
2016-09-21 11:51             ` Adam Porter
2016-09-21 12:49               ` Rainer M Krug
2016-11-29 19:23                 ` Alexander Vorobiev
2016-11-29 21:05                   ` Nick Dokos
2016-11-30  5:15                     ` Alexander Vorobiev
2016-11-30 16:45                       ` Nick Dokos

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=87vaxr51t3.fsf@gmail.com \
    --to=ndokos@gmail.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).