From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kaushal Modi Subject: Re: Bug: Org Capture with Concatenated filenames [9.0 (9.0-elpa @ .emacs.d/elpa/org-20161102/)] Date: Fri, 04 Nov 2016 22:36:24 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11484bd08a85960540814e6f Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49110) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c2n6E-0000Hm-US for emacs-orgmode@gnu.org; Fri, 04 Nov 2016 18:36:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c2n6D-0005pP-Ov for emacs-orgmode@gnu.org; Fri, 04 Nov 2016 18:36:38 -0400 Received: from mail-vk0-x231.google.com ([2607:f8b0:400c:c05::231]:34034) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1c2n6D-0005oE-EK for emacs-orgmode@gnu.org; Fri, 04 Nov 2016 18:36:37 -0400 Received: by mail-vk0-x231.google.com with SMTP id x186so79097961vkd.1 for ; Fri, 04 Nov 2016 15:36:37 -0700 (PDT) In-Reply-To: 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" To: Klarre N , emacs-orgmode@gnu.org --001a11484bd08a85960540814e6f Content-Type: text/plain; charset=UTF-8 Hi Klarre, The org 9.0 release had deprecated use of S-exps in org-capture-templates. That, though, went undocumented. So for now, that deprecation is reverted on the main branch and moved to the master/dev branch. http://orgmode.org/cgit.cgi/org-mode.git/commit/?id=f5645675a336d8f56fa9e6bd63832bdbac71f315 So when org stable next updates on Elpa (probably on Monday?), that will have this reverted commit in it. But going forward, when org 9.1 is released, the use of S-exp will once again be deprecated. So it would be best to replace that S-exp with a function wrapper. On Fri, Nov 4, 2016 at 6:19 PM Klarre N wrote: > Hi, > concatenated filenames for org-capture templates no longer works (since > 9.0). > > ECM: > (setq org-default-notes-file "absolute-path/default.org") > (defvar absolute "absolute-path/" > "Path to Desired directory.") > (setq org-capture-templates '( > ("e" "Example" entry > (file+headline (concat absolute "example.org") "Example") > "* Capture" > :empty-lines 1))) > > Expected result: > Add "* Capture" to absolute-path/example.org. > > Result: "* Capture" is added to "absolute-path/default.org". > > This provides the desired result, but unable to use variable filenames > (very useful): > (setq org-default-notes-file "absolute-path/default.org") > (setq org-capture-templates '( > ("e" "Example" entry > (file+headline "absolute-path/example.org" "Example") > "* Capture" > :empty-lines 1))) > > > Thanks! > -- Kaushal Modi --001a11484bd08a85960540814e6f Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi Klarre,

The org 9.0 release had depr= ecated use of S-exps in org-capture-templates. That, though, went undocumen= ted. So for now, that deprecation is reverted on the main branch and moved = to the master/dev branch.


So when org st= able next updates on Elpa (probably on Monday?), that will have this revert= ed commit in it. But going forward, when org 9.1 is released, the use of S-= exp will once again be deprecated. So it would be best to replace that S-ex= p with a function wrapper.

On Fri, Nov 4, 2016 at 6:19 PM Klarre N <klarre@gmail.com> wrote:
Hi,
concatenated filenames for org-capture templates no longer works= (since 9.0).

=
ECM:
(setq org-default-notes-file &qu= ot;absolute-path/default.org")
(defvar absolute = "absolute-path/"
=C2=A0=C2=A0=C2=A0 "= Path to Desired directory.")
(setq org-capture-= templates '(
=C2=A0 ("e" "Example= " entry
=C2=A0=C2=A0 (file+headline (concat abs= olute "example.org") "Example")
= =C2=A0=C2=A0 "* Capture"
=C2=A0=C2=A0 :emp= ty-lines 1)))

=
Expected result:
=
= Add "* Capture" to absolute-path/example.org.

Result: "* Capture" is added to= "absolute-path/default.org".

This provides the desired result, but unable to use= variable filenames (very useful):
(= setq org-default-notes-file "absolute-path/default.org")
(setq org-capture-templates '(
= =C2=A0 ("e" "Example" entry
=C2= =A0=C2=A0 (file+headline "absolute-path/example.org" "Example&= quot;)
=C2=A0=C2=A0 "* Capture"
=C2=A0=C2=A0 :empty-lines 1)))



Thanks!
--

Kaushal Modi

--001a11484bd08a85960540814e6f--