From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gerald Wildgruber Subject: Re: how to convert/normalize plain footnotes into [fn:] ones Date: Fri, 23 Dec 2016 14:57:44 +0100 Message-ID: References: <878tr9xp16.fsf@nicolasgoaziou.fr> <871sx1xcr9.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49003) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cKQME-0004iL-8G for emacs-orgmode@gnu.org; Fri, 23 Dec 2016 08:58:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cKQMA-0007Du-Ce for emacs-orgmode@gnu.org; Fri, 23 Dec 2016 08:58:02 -0500 Received: from mx1-priv.urz.unibas.ch ([131.152.226.164]:44209) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cKQMA-0007DI-4p for emacs-orgmode@gnu.org; Fri, 23 Dec 2016 08:57:58 -0500 In-reply-to: <871sx1xcr9.fsf@nicolasgoaziou.fr> 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: Nicolas Goaziou Cc: org mode mailing list Hi Nicolas, thanks again! On Mi, Dez 21 2016, Nicolas Goaziou wrote: > I would use (and, in fact, used) > > \\[\\([0-9]+\\)\\] --> \\[fn:\\1\\] > > and eyeballing the results. That works quite well; but as I'm trying to convert a whole book I also have lots of "\cite[NUMBER]{my_ref}" commands from TeX; and these all give false positives with the regex above. Actually I couldn't figure out what a regex would have to look like that excludes occurences of the mentioned expression if they are preceded by "cite". >> The problem unfortunately arises also by pandoc still using the now >> obsolete syntax of plain footnotes when converting (e.g. latex) to org >> mode! > > I'm certain Pandoc importer will ultimately catch-up. Yes, I posted the problem on the pandoc mailing list and Albert Krewinkel kindly fixed it immediately and pushed the code to the dev version of pandoc: https://github.com/jgm/pandoc/commit/d27188ad309feb9a76f6dc3d816ad78722078fe1 I checked out the haskell source, compiled it and it works perfectly now! The org writer produces the correct footnote format. Gerald.