From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthew Lundin Subject: Re: Use variable filename for remember template? Date: Mon, 06 Jul 2009 19:35:41 -0500 Message-ID: <87y6r1qqhu.fsf@fastmail.fm> References: <211769420907061527x410f47f6n7370768c24fc5ebb@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MNycm-0002BZ-69 for emacs-orgmode@gnu.org; Mon, 06 Jul 2009 20:33:32 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MNych-00028u-3l for emacs-orgmode@gnu.org; Mon, 06 Jul 2009 20:33:31 -0400 Received: from [199.232.76.173] (port=43194 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MNycg-00028r-U3 for emacs-orgmode@gnu.org; Mon, 06 Jul 2009 20:33:26 -0400 Received: from out1.smtp.messagingengine.com ([66.111.4.25]:58217) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MNycg-0000VS-JF for emacs-orgmode@gnu.org; Mon, 06 Jul 2009 20:33:26 -0400 In-Reply-To: <211769420907061527x410f47f6n7370768c24fc5ebb@mail.gmail.com> (Nathan Neff's message of "Mon, 6 Jul 2009 17:27:19 -0500") 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: Nathan Neff Cc: emacs-orgmode@gnu.org Nathan Neff writes: > 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. How about the following? --8<---------------cut here---------------start------------->8--- (setq org-remember-templates '(("Book" ?b "\n* %^{Book Title} %t :READING: \n%[~/personal/booktemp.txt]\n" "L:journal.org") )) --8<---------------cut here---------------end--------------->8--- Best, Matt