From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: BUG? - Capture escape %n not working Date: Fri, 7 Jan 2011 15:29:11 +0100 Message-ID: <3FAC4D78-B270-405A-98DB-8E7F8D03BA0B@gmail.com> References: <4D26CE96.4090408@gmail.com> <12644.1294409728@gamaville.dokosmarshall.org> Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=49522 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PbDJc-0007df-61 for emacs-orgmode@gnu.org; Fri, 07 Jan 2011 09:29:18 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PbDJa-0003o6-Gf for emacs-orgmode@gnu.org; Fri, 07 Jan 2011 09:29:16 -0500 Received: from mail-ew0-f41.google.com ([209.85.215.41]:58673) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PbDJa-0003nu-Bq for emacs-orgmode@gnu.org; Fri, 07 Jan 2011 09:29:14 -0500 Received: by ewy27 with SMTP id 27so8529992ewy.0 for ; Fri, 07 Jan 2011 06:29:13 -0800 (PST) In-Reply-To: <12644.1294409728@gamaville.dokosmarshall.org> 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: nicholas.dokos@hp.com Cc: emacs-orgmode , Rainer M Krug Applied, thanks. - Carsten On Jan 7, 2011, at 3:15 PM, Nick Dokos wrote: > Rainer M Krug wrote: > >> Hi >> >> I am not sure if it is a bug, or a configuration issue, but %n (user >> name (taken from `user-full-name')) is not working - it is not >> expanded >> and displayed as %n >> >> Emacs : GNU Emacs 23.2.1 (i686-pc-linux-gnu, GTK+ Version 2.20.1) >> of 2010-07-05 on ecolmod >> Package: Org-mode version 7.4 (release_7.4.100.gdf7d) >> > > It's a bug - there is an "n" missing from the regexp: > > diff --git a/lisp/org-capture.el b/lisp/org-capture.el > index 85747ee..2076f68 100644 > --- a/lisp/org-capture.el > +++ b/lisp/org-capture.el > @@ -1213,7 +1213,7 @@ The template may still contain \"%?\" for > cursor positioning." > > ;; Simple %-escapes > (goto-char (point-min)) > - (while (re-search-forward "%\\([tTuUaiAcxkKI]\\)" nil t) > + (while (re-search-forward "%\\([tTuUaiAcxkKIn]\\)" nil t) > (unless (org-capture-escaped-%) > (when (and initial (equal (match-string 0) "%i")) > (save-match-data > > Nick > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode - Carsten