emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Oleh <ohwoeowho@gmail.com>
To: org mode <emacs-orgmode@gnu.org>
Subject: org-mode `org-capture-templates' %(sexp) must return string restriction
Date: Fri, 26 Jul 2013 09:09:44 +0200	[thread overview]
Message-ID: <CAA01p3pAEdo_woh4hRqX4tLQ3dQeZhnFneArrSkn3kKeUgrXKA@mail.gmail.com> (raw)

Hi all,

Is this restriction really necessary?
This results in code like:

(setq
 org-capture-templates
 '(("e" "elisp todo"
    entry
    (file+headline (concat org.d "gtd.org") "Tasks")
    "* TODO %(progn (org-set-tags-to \"ELISP\") \"\")%^{Brief
Description}\n  Added: %U  %i\n  %?\n")))

I think it should be fine to just return nil. That would be equivalent
to the empty string.
Here's the same code if returning nil would be acceptable:

(setq
 org-capture-templates
 '(("e" "elisp todo"
    entry
    (file+headline (concat org.d "gtd.org") "Tasks")
    "* TODO %(org-set-tags-to \"ELISP\")%^{Brief Description}\n
Added: %U  %i\n  %?\n")))

Any opinions on this?

regards,
Oleh

             reply	other threads:[~2013-07-26  7:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-26  7:09 Oleh [this message]
2013-08-08  7:11 ` org-mode `org-capture-templates' %(sexp) must return string restriction Carsten Dominik

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=CAA01p3pAEdo_woh4hRqX4tLQ3dQeZhnFneArrSkn3kKeUgrXKA@mail.gmail.com \
    --to=ohwoeowho@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).