emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nathan Neff <nathan.neff@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Use variable filename for remember template?
Date: Mon, 6 Jul 2009 17:27:19 -0500	[thread overview]
Message-ID: <211769420907061527x410f47f6n7370768c24fc5ebb@mail.gmail.com> (raw)

Hello,

I am able to successfully read the contents of
"/Users/nate/personal/booktemp.txt" into a new remember-note.

(setq org-remember-templates
     '(("Book" ?b "\n* %^{Book Title} %t :READING:
\n%[/Users/nate/personal/booktemp.txt]\n"
              "L:journal.org")
      ))

Now, I'd like to be able to specify an environment variable like $HOME
instead of /Users/nate.

I'm a lisp beginner, and have tried something like

(setq personal-home-dir (getenv "HOME"))

(setq org-remember-templates
     '(("Book" ?b (concat "\n* %^{Book Title} %t :READING: \n%["
personal-home-dir "/personal/booktemp.txt]\n")
              "L:journal.org")
      ))

but I keep getting "Wrong type argument char-or-string-p" errors.

I'm guessing that the org-remember-templates function wants something
other than a string, but I don't know
where to go from here.

Any help is appreciated.

Thanks,
-Nate

             reply	other threads:[~2009-07-06 22:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-06 22:27 Nathan Neff [this message]
2009-07-07  0:35 ` Use variable filename for remember template? Matthew Lundin
2009-07-07  2:42 ` 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=211769420907061527x410f47f6n7370768c24fc5ebb@mail.gmail.com \
    --to=nathan.neff@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).