From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/28960 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Bastien DUMONT Newsgroups: gmane.text.pandoc Subject: Re: LaTeX footnote citations parentheses Date: Mon, 2 Aug 2021 09:59:57 +0000 Message-ID: References: <26bec817-c8b4-4d63-ad5d-436aa281c0d7n@googlegroups.com> <7c5a2709-9b84-40b4-a77e-bd3dc5acb50cn@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21858"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-X-From: pandoc-discuss+bncBDCINCES2QJRB2MET6EAMGQE7MITAGY-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mon Aug 02 12:01:17 2021 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-wm1-f60.google.com ([209.85.128.60]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mAUl1-0005Tn-Nw for gtp-pandoc-discuss@m.gmane-mx.org; Mon, 02 Aug 2021 12:01:15 +0200 Original-Received: by mail-wm1-f60.google.com with SMTP id d72-20020a1c1d4b0000b029025164ff3ebfsf4914903wmd.7 for ; Mon, 02 Aug 2021 03:01:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1627898475; cv=pass; d=google.com; s=arc-20160816; b=cCdMSfYgg0ePDDHsTBC03n2PTObCJqTBZqnwgtifa+cPdqII0pIBvu9H/7qCmV95Zl qBxGNVADRpjUe0uRCgiok5IkOrWnSc+6dhy7kF8rZX3kQ8+n12n0dpzcBi956xijXWwd +qWKBmL2e6NqycVYZxoAXZdNh0o6vmb4RTAnQ4QOMGqGN140VIT9ZmBMoK9JwfQ2z/CC IWARdMFWIoRojLJt8cwZfHyIkXAj4sCS+t+TRr9JFt91o0NPzD7sBnpwW/VC54FzmW5D 03ghwSmEbPW6WPIDX2WpZ04+PW6+WkT/NL8BcSyf7wuUGCNZ8wf8bc6i5IYASvGMZHxL TN9A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:to:from:date:sender:dkim-signature; bh=Dp0DXqItYz5fOfiMHMkjhGaewo8o38QVw6isRkEFn6o=; b=Jc6CrqkmMybh5AQuTOiPaXz/ICavqyKPNwpucB9ifik6K2BaHAphw6/oeXbCaBWfig gzaSmwm7rPtkbh7nKChqdhuLSY8d4LOB+woWJT9y+SYwZ9tQOZnyzpsYtWPq6H5oIzbB 2IutfoPEqxpQY6uU9YRxLyK+gcGtxgsxuA2CYRltnqDxxzmUu5j119H2mtbDnsZMC/zQ gWLi0txatlloUmNEMK6qBVl74YpxfFKGFAdDx0CN1jCgkoxp+An4a7I6ZrHcUkls+tY4 9usKwioSM0WG1RsSweOO66CRofqQ7sMJSrwNAnm86GBKWo7o70PijAPToEQeKJh1nXQt yS4Q== ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@posteo.net header.s=2017 header.b=AGy1ab6w; spf=pass (google.com: domain of bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org designates 185.67.36.65 as permitted sender) smtp.mailfrom=bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=posteo.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:date:from:to:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :x-original-sender:x-original-authentication-results:reply-to :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=Dp0DXqItYz5fOfiMHMkjhGaewo8o38QVw6isRkEFn6o=; b=cEiww/y7O/2gFRXSRq4Fte8C96Mrh+nKy+qO/kYPedNbLSFqipLBoixP3HPiRbhLnv Ps9zeWvRkvfHPUptkc8XyHRR3//3q3Mp7Pbx1oz3PJa3ur1itlV6ygR/SxCQTPlybEiD tYmpOc4ea4GBxcHn/rPTnJaQx4SMmZSbQFFilCZq/4LaYfbmM7Ns3quSsD6TLjnvwmB+ pgqFZtEU0ekuT+qtt6uJY6sGROe8tyne19rhygs4rB8hZtLcThr9DU0L5b9v2ffyiLWh a41o6sEnorwOC8AztwxcazPGp+87Nqj1va2TVymtOjnGXTNhcfpQyojobvgfPu7MS2xi jEwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:date:from:to:subject:message-id :references:mime-version:content-disposition :content-transfer-encoding:in-reply-to:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:x-spam-checked-in-group:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=Dp0DXqItYz5fOfiMHMkjhGaewo8o38QVw6isRkEFn6o=; b=V8xfUKSfbR/oU0qhUUZ5+lFTN7NxVxgR2sgq9BrqAOQfI0GG1oixPnjFGvIm2Og3SR cf//SGLBM3nbiG7ER74xukMU9juNLrTTmV9b5cGZaT+7pqfYKC/beb45qT5/ewo6K3Tg yrjO8rse/+AHB0vG4ytnug6wrXemJ2anT8FCowm48fxCB2aMScQRJI/NLohRCsUPRNWC m0ZQrWEaMp2PtvpbYxdbTDsIe9PF5XP/xJ2n6agGjzO0UPS/QIWZuoim4vqnG1J1qdgu x4NUoF5JNtGCGWkgK6XODmvTkXiUXfPdVnAcFB9EhNzL Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOAM531sYTC9SV43MIiIUF9cPO3mjkeQjmXXx3pUcXDBx3bzIc0izJeN yXLKS26AEqEvFjDPQg825i8= X-Google-Smtp-Source: ABdhPJxt85sOr1/9kGisVTqPky/Y+8JgOymzPK7WlgZcJUzCM+wmOKQL9cN6lI4Jxyca6pR7Wvgf9w== X-Received: by 2002:adf:f149:: with SMTP id y9mr17067456wro.413.1627898475072; Mon, 02 Aug 2021 03:01:15 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a1c:7fc3:: with SMTP id a186ls4608038wmd.3.gmail; Mon, 02 Aug 2021 03:01:12 -0700 (PDT) X-Received: by 2002:a1c:7e0d:: with SMTP id z13mr15605182wmc.153.1627898472500; Mon, 02 Aug 2021 03:01:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627898472; cv=none; d=google.com; s=arc-20160816; b=abapFvxR3mUy3L4D/p6WUp17d+fvOmVxt3x/Efou31Wa29s/4budlxXZNBhxFUSE4i KIqsPq9bQlFOIZNRc3VFV1qCJMVQQpxLURb0tUprLk31jIUSJHnsUUsLjNv/wt5E38zX MFpDLq/ef900qOs47VIpUePQmwwEAU1AnrAByGL836eloanLW8RwSpT60vojBoppjyZ1 mbYRUsMslSmBBPZ7Bnz49bh3Oq941YJaZYHeCwqG5Kp5PeB/02SQWCdC35F/zTCDvsLs t+hgZyqnjJA9toiy72bVlidPoC5mPkUvwy3g/xt8S2KRRRovB6mnGCNj2NDviD5uCuU6 42BQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:to:from:date :dkim-signature; bh=ADaGT+GX1C1jV3Lt6dJJm+kAC2PA3YJbByEFwotBZmQ=; b=LSHBG1j6XgHJdVLD7sBQ7LhbzjmPKpKhK1VpTjQ9aqCPZxM7MXTiVsy+YwEkuPjXM3 t0weBDrAVftZ6eNYiFcQMF0w20MOAWRd1OHPHsrx4EbIxAgLXIQl8VXF/IJxvbsVV4st kwEeCPeogaQDj6FXz1cGraARB8I1ItV1U9BOmpmrwoYqiVZEu4VdJ1UV3ytJwOagr305 n8UwkX8tPD48bvnhRkMDkuNXT6SC8cPrpJsoPWn4wHwQSHCIhTlzjRx4JlRgnNXsGCca c2XlI5Pf11JPOb7vta71EQTsYA1tWRPz/DmF8nbfPa7qk11HQ0RklCCYvfgmVG1xoE6N 1HzA== ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@posteo.net header.s=2017 header.b=AGy1ab6w; spf=pass (google.com: domain of bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org designates 185.67.36.65 as permitted sender) smtp.mailfrom=bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=posteo.net Original-Received: from mout01.posteo.de (mout01.posteo.de. [185.67.36.65]) by gmr-mx.google.com with ESMTPS id 14si448240wmk.2.2021.08.02.03.01.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Aug 2021 03:01:12 -0700 (PDT) Received-SPF: pass (google.com: domain of bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org designates 185.67.36.65 as permitted sender) client-ip=185.67.36.65; Original-Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 230A2240026 for ; Mon, 2 Aug 2021 12:01:12 +0200 (CEST) Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4GdYRq5j5Fz6tmK for ; Mon, 2 Aug 2021 12:01:11 +0200 (CEST) Content-Disposition: inline In-Reply-To: X-Original-Sender: bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@posteo.net header.s=2017 header.b=AGy1ab6w; spf=pass (google.com: domain of bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org designates 185.67.36.65 as permitted sender) smtp.mailfrom=bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=posteo.net Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:28960 Archived-At: Hi, I just returned from an internet-free stay in a bucolic region of France. A= s this issue with the last upgrade may impact my own workflow, I probably w= ill look into it and give you a notice if I find a solution. Best, Bastien Le Tuesday 20 July 2021 =C3=A0 10:44:14AM, Jeffrey T a =C3=A9crit : > Hi John,=20 >=20 > Thank you for the reply!=20 >=20 > I've been trying to get Bastien's Lua filter to work again and think I ma= y have > discovered the issue... Since the filter had always worked until recently= , I > suspected the problem may have something to do with a Pandoc update. So I > uninstalled the most recent version of Pandoc and re-installed version 2.= 13. > This appears to have fixed the issue and everything is working as intende= d! Not > sure why the newer releases are incompatible or causing issues? Regardles= s, I > saved the installation package for 2.13 for future use! >=20 > That said, it sounds like the best method of using Pandoc is with markdow= n? >=20 > On Tuesday, July 20, 2021 at 12:19:43 PM UTC-4 John MacFarlane wrote: >=20 >=20 > I guess what you want is for an autocite in a footnote not to > include the surrounding parentheses. >=20 > There's actually no CSL setting that says "omit parentheses." > We can have a normal citation (which may have parentheses if > that's what the style dictates) or an author-in-text citation > (which will typically have parentheses around everything but > the author name). >=20 > So we may not be able to do better here, given the impedance > mismatch between biblatex and CSL... >=20 > Jeffrey T writes: >=20 > > Hi Bastien, > > > > I'm working on converting a manuscript for a revise and submit. > > Unfortunately I've suddenly encountered a new error with the Pandoc > script > > / filter which appears to be isolated to citations that appear in a > > footnote but *without* any preceding text. I've attached a minimal > working > > example. Note the third citation in the example appears to be the > culprit. > > Indeed, by adding any arbitrary character in front of \autocite com= mand > > contained within a footnote the conversion seems to work as intende= d. > > > > Any suggestions? Is this new error perhaps related to a newer relea= se of > > Pandoc? As always, your expertise and help is greatly appreciated! > > > > On Wednesday, May 19, 2021 at 3:55:21 AM UTC-4 Bastien Dumont wrote= : > > > >> Unless you modify it in order to produce nuclear bombs, do as you = wish! > >> However, I must warn you that I adapted it to work with the use ca= se > >> that you provided only: there are no checks that would prevent it = to run > >> into errors if other conditions are met. Ensure that you stick to = \cite > >> in footnotes and \autocite in the body text, or modify the script > >> accordingly. > >> > >> Le Tuesday 18 May 2021 =C3=A0 07:21:54PM, Jeffrey T a =C3=A9crit : > >> > > >> > Hi Bastien, > >> > > >> > Thank you very much! This script with Pandoc is an absolute game > changer > >> in > >> > terms of my workflow! Do you mind if I share your script with ot= hers? > >> > > >> > Again, thank you! > >> > On Sunday, May 16, 2021 at 12:54:24 PM UTC-4 Bastien Dumont wrot= e: > >> > > >> > You're welcome, I already had done much of the work for myself, = so I > am > >> > happy if > >> > it could be useful for others as well. > >> > > >> > I had'nt anticipat=C4=95d that you would also use \autocite in t= he body. I > >> > restricted > >> > the scope of the filter to the footnotes, so you should not have > errors > >> > anymore > >> > provided that all your use cases are documented in the text file= . I > >> > supposed that > >> > you don't want the output of \autocite to be changed. Please try= the > file > >> > attached. > >> > > >> > Le Saturday 15 May 2021 =C3=A0 08:34:22PM, Jeffrey T a =C3=A9cri= t : > >> > > Hi Bastien, > >> > > > >> > > Oh my, thank you very much for taking the time to assist! I > downloaded > >> > your Lua > >> > > filter (I didn't realize that filters were possible with Pando= c!) > and > >> > included > >> > > it in my Pandoc command: > >> > > > >> > > pandoc --citeproc --lua-filter=3Dremove-parentheses-from-cite.= lua > >> Test.tex > >> > > --bibliography=3Dtestref.bib --csl=3D > >> > > chicago-fullnote-bibliography-short-title-subsequent.csl -o > test.docx > >> > > > >> > > It worked perfectly for the \cite commands contained within \ > footnote. > >> > > Unfortunately the remainder of my book manuscript uses \autoci= te for > >> > references > >> > > outside of footnotes. When \autocite is included, I received a= n > error > >> > message: > >> > > "bad argument #1 to 'gsub' (string expected, got nil)" > >> > > > >> > > If helpful, I've attached the test .tex file I'm using? Your > assistance > >> > is much > >> > > appreciated! > >> > > > >> > > > >> > > On Saturday, May 15, 2021 at 6:05:21 PM UTC-4 Bastien Dumont w= rote: > >> > > > >> > > I had a similar problem that I resolved with the attached Lua = filter > >> > > (slightly > >> > > modified to adapt it to your needs). I hope that it will work = for > you. > >> > > Simply > >> > > call it after --citeproc. > >> > > > >> > > Note that it will throw an error if you have \cite commands ou= tside > >> > > footnotes. > >> > > If that it the case, please let me know. > >> > > > >> > > Le Saturday 15 May 2021 =C3=A0 12:13:37PM, Jeffrey T a =C3=A9c= rit : > >> > > > > >> > > > Hi all, > >> > > > I'm new to the group and Pandoc and would greatly appreciate= your > >> > > assistance. > >> > > > I'm attempting to convert my LaTeX book manuscript into a Wo= rd doc > >> for > >> > my > >> > > > editor. Using a test .tex file, I have successfully converte= d the > >> file > >> > > using > >> > > > the following command in Mac Terminal : > >> > > > pandoc --citeproc Test.tex --bibliography=3Dtestref.bib --cs= l=3D > >> > > > chicago-fullnote-bibliography-short-title-subsequent.csl -o > test.docx > >> > > > It works wonderfully, however, the only issue concerns the \= cite > >> > > contained > >> > > > within \footnote. In particular, the resulting citation is n= ow > placed > >> > > within > >> > > > parentheses which my editor has asked me to remove. Is there= some > >> sort > >> > of > >> > > > solution to my dilemma? Given the length of the book I fear = it > will > >> be > >> > > quite > >> > > > tedious to find/remove the offending parentheses manually. > >> > > > Thank you in advance! > >> > > > > >> > > > -- > >> > > > You received this message because you are subscribed to the = Google > >> > Groups > >> > > > "pandoc-discuss" group. > >> > > > To unsubscribe from this group and stop receiving emails fro= m it, > >> send > >> > an > >> > > email > >> > > > to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > >> > > > To view this discussion on the web visit > >> [1]https://groups.google.com/d/ > >> > > msgid/ > >> > > > pandoc-discuss/f4c18da4-6145-4f93-8779-fe2bd2816c38n% > >> [2]40googlegroups.com > >> > . > >> > > > >> > > > >> > > -- > >> > > You received this message because you are subscribed to the Go= ogle > >> Groups > >> > > "pandoc-discuss" group. > >> > > To unsubscribe from this group and stop receiving emails from = it, > send > >> an > >> > email > >> > > to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > >> > > To view this discussion on the web visit [3]https:// > groups.google.com/d/ > >> > msgid/ > >> > > pandoc-discuss/26bec817-c8b4-4d63-ad5d-436aa281c0d7n% > >> [4]40googlegroups.com. > >> > > >> > > >> > > >> > -- > >> > You received this message because you are subscribed to the Goog= le > Groups > >> > "pandoc-discuss" group. > >> > To unsubscribe from this group and stop receiving emails from it= , send > >> an email > >> > to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > >> > To view this discussion on the web visit > >> [5]https://groups.google.com/d/msgid/ > >> > pandoc-discuss/f787dab5-f3ce-41cf-815c-21f24727b781n%[6] > 40googlegroups.com. > >> > >> > > > > -- > > You received this message because you are subscribed to the Google = Groups > "pandoc-discuss" group. > > To unsubscribe from this group and stop receiving emails from it, s= end an > email to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > To view this discussion on the web visit [7]https://groups.google.c= om/d/ > msgid/pandoc-discuss/ > 7c5a2709-9b84-40b4-a77e-bd3dc5acb50cn%40googlegroups.com. > > \documentclass{article} > > > > \usepackage{markdown} > > \usepackage{biblatex-chicago} > > > > \usepackage{filecontents}% to embed the file `myreferences.bib` in = your > `.tex` file > > > > \begin{filecontents}{testref.bib} > > @article{Doe, > > author =3D {John Doe}, > > journal =3D {Sample Journal}, > > number =3D {1}, > > pages =3D {1-20}, > > title =3D {This is a sample title of the Pandoc reference}, > > volume =3D {14}, > > year =3D {2022}} > > > > @article{Smith, > > author =3D {Sally Smith}, > > journal =3D {Journal of Something}, > > number =3D {4}, > > pages =3D {69-90}, > > title =3D {The title would normally goes here}, > > volume =3D {02}, > > year =3D {1992}} > > \end{filecontents} > > > > \addbibresource{testref.bib} > > > > \begin{document} > > > > Here is a standard citation using autocite.\autocite[1]{Doe} > > > > Here is a citation contained within a footnote.\footnote{See \autoc= ite[6] > {Smith}.} > > > > Here is a citation contained within a footnote but without any prec= eding > text before the citation.\footnote{\autocite[10]{Doe}. See also \auto= cite > {Smith}.} > > > > > > \end{document} >=20 > -- > You received this message because you are subscribed to the Google Groups > "pandoc-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an= email > to [8]pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit [9]https://groups.google.com/d/m= sgid/ > pandoc-discuss/daaa9fdd-787c-4a51-bde0-c307396fd835n%40googlegroups.com. >=20 > References: >=20 > [1] https://groups.google.com/d/ > [2] http://40googlegroups.com/ > [3] https://groups.google.com/d/ > [4] http://40googlegroups.com/ > [5] https://groups.google.com/d/msgid/ > [6] http://40googlegroups.com/ > [7] https://groups.google.com/d/msgid/pandoc-discuss/7c5a2709-9b84-40b4-a= 77e-bd3dc5acb50cn%40googlegroups.com > [8] mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org > [9] https://groups.google.com/d/msgid/pandoc-discuss/daaa9fdd-787c-4a51-b= de0-c307396fd835n%40googlegroups.com?utm_medium=3Demail&utm_source=3Dfooter --=20 You received this message because you are subscribed to the Google Groups "= pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/YQfCHT7GWWZfPZtv%40localhost.