From mboxrd@z Thu Jan 1 00:00:00 1970 From: Xavier Maillard Subject: Define org-capture-templates with variables via customize Date: Mon, 30 Mar 2015 06:07:17 +0200 Message-ID: <86oanbxh56.fsf@kcals2.maillard.im> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43112) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcRv1-00005P-R9 for emacs-orgmode@gnu.org; Mon, 30 Mar 2015 01:07:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YcRuv-0003Lj-V5 for emacs-orgmode@gnu.org; Mon, 30 Mar 2015 01:07:23 -0400 Received: from out2-smtp.messagingengine.com ([66.111.4.26]:56994) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YcRuv-0003LX-Jx for emacs-orgmode@gnu.org; Mon, 30 Mar 2015 01:07:17 -0400 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 9AE0120939 for ; Mon, 30 Mar 2015 01:07:13 -0400 (EDT) Received: from kcals2.maillard.im (unknown [92.142.172.180]) by mail.messagingengine.com (Postfix) with ESMTPA id 1B441C0001A for ; Mon, 30 Mar 2015 01:07:15 -0400 (EDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org Mode Hello, Given the fact I defvar'ed a custom variable holding a template of my own: #+BEGIN_SRC emacs-lisp (defvar xma/org-task-with-effort-template "* TODO %^{Task} %U SCHEDULED: %^t :PROPERTIES: :Effort: %^{effort|1:00|0:30|0:05|0:15|2:00|3:00|4:00} :END: %? %a " "Une tache avec une duree d'effort") #+END_SRC How would you use that in a template declared via the customize UI ? How to do the equivalent of this: #+BEGIN_SRC emacs-lisp (setq org-capture-templates `(("e" "Task with effort" entry (file "~/Dropbox/refile.org") ,xma/org-task-with-effort-template))) #+END_SRC ? Thank you -- Xavier.