From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/7569 Path: news.gmane.org!not-for-mail From: John MacFarlane Newsgroups: gmane.text.pandoc Subject: Re: Decoupling citeproc and highlighting-kate from pandoc Date: Mon, 30 Sep 2013 19:49:28 -0700 Message-ID: <20131001024928.GA24084@Johns-MacBook-Pro.local> References: <20130929014129.GA45834@Johns-MacBook-Pro.local> <20130929144959.GD1060@Johns-MacBook-Pro.local> <20130929170210.GA24069@Johns-MacBook-Pro.local> <2e05de82-6208-49bf-be01-1f5f710c89de@googlegroups.com> <20130930025139.GA1405@Johns-MacBook-Pro.local> <5249C9FC.4010603@gmail.com> <66a61c32-a3b4-45c2-b548-442592eab56d@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1380597255 27157 80.91.229.3 (1 Oct 2013 03:14:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 1 Oct 2013 03:14:15 +0000 (UTC) To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-X-From: pandoc-discuss+bncBDW7ZIEHTIIBBB74VCJAKGQEDNMDW7Y-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Tue Oct 01 05:14:19 2013 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane.org Original-Received: from mail-gg0-f183.google.com ([209.85.161.183]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VQqPg-0001uw-Ia for gtp-pandoc-discuss@m.gmane.org; Tue, 01 Oct 2013 05:14:16 +0200 Original-Received: by mail-gg0-f183.google.com with SMTP id q4sf398789ggn.0 for ; Mon, 30 Sep 2013 20:14:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20120806; h=date:from:to:subject:message-id:references:mime-version:in-reply-to :user-agent:x-original-sender:x-original-authentication-results :reply-to:precedence:mailing-list:list-id:list-post:list-help :list-archive:sender:list-subscribe:list-unsubscribe:content-type :content-disposition; bh=m+P0adF1ReKL3UV5xoTKiWqwHxssK8Mil2MxFVCxz7M=; b=qvZOryj9y4esChDIoRV1Jels3/kr7jMltO9dFJz1bcop+WsYJU+ZcRgNAdPfw6Rbsw tMFj08FjKlyogIgYFw+TZ3ZBXNsnoXFKtyOVSWo5uk7rdbdSkhdmBXUseKsb2oevP7hE OnQgC61yKCJ44zEs7LN8VEc3GP3sOZQ1BrQZtPt3YQGqLXgM3fpyEveDr7Fc9DL9LBDl oNlCFVwYpAEbOOdbB21GFepmmqE7Zx+GEapr/UerIQQ9eEovD8wzFRIQHw8c8E0/ZrAi M35g07vWv2qQDJNsVay99ff8aOqthFvoG4UHZkpk2rBIZKKPUVHjpoi0sJMl+Rr2f3ix tIIQ== X-Received: by 10.50.25.40 with SMTP id z8mr314765igf.15.1380597255733; Mon, 30 Sep 2013 20:14:15 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 10.50.73.106 with SMTP id k10ls2340546igv.3.gmail; Mon, 30 Sep 2013 20:14:15 -0700 (PDT) X-Received: by 10.66.250.233 with SMTP id zf9mr23791295pac.12.1380597255193; Mon, 30 Sep 2013 20:14:15 -0700 (PDT) Original-Received: from cm05fe.IST.Berkeley.EDU (cm05fe.IST.Berkeley.EDU. [169.229.218.146]) by gmr-mx.google.com with ESMTPS id dk16si594549pac.0.1969.12.31.16.00.00 (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 30 Sep 2013 20:14:15 -0700 (PDT) Received-SPF: neutral (google.com: 169.229.218.146 is neither permitted nor denied by best guess record for domain of jgm-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org) client-ip=169.229.218.146; Original-Received: from li55-134.members.linode.com ([74.82.3.134] helo=johnmacfarlane.net) by cm05fe.ist.berkeley.edu with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.76) (auth plain:jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org) (envelope-from ) id 1VQqPe-0002xs-GQ for pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; Mon, 30 Sep 2013 20:14:14 -0700 Original-Received: by johnmacfarlane.net (Postfix, from userid 1000) id 3DE89BBBE0; Mon, 30 Sep 2013 22:52:24 -0400 (EDT) In-Reply-To: <66a61c32-a3b4-45c2-b548-442592eab56d-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> X-PGP-Key: http://johnmacfarlane.net/jgm.asc User-Agent: Mutt/1.5.21 (2010-09-15) X-Original-Sender: fiddlosopher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 169.229.218.146 is neither permitted nor denied by best guess record for domain of jgm-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org) smtp.mail=jgm-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org; dmarc=fail (p=NONE dis=NONE) header.from=gmail.com 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: Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-Subscribe: , List-Unsubscribe: , Content-Disposition: inline Xref: news.gmane.org gmane.text.pandoc:7569 Archived-At: Thanks, patch applied. I'm beginning to rethink the general approach a bit. Currently bibtex2pandoc reads the bibtex file, converts it to a pandoc 'MetaValue', and uses the markdown writer to write it out as YAML metadata. This is fairly nice if you want to convert a bibtex file to a format in which it can be used inline in pandoc, but it makes less sense if you're using an external bibtex file as your bibliography. For that, it would make more sense to convert directly to a list of citeproc Reference objects. We've defined ToJSON and FromJSON instances for these, so it's easy to convert to JSON or YAML (that's what biblio2yaml does). However, the YAML produced will be slightly different: it will have this kind of emphasis instead of *standard markdown* emphasis, for example. It seems that ultimately we're going to want to integrate the code we're writing into pandoc-citeproc itself, so that we can avoid the bibutils conversion step when using bibtex/biblatex bibliographies. That suggests targeting [Reference] rather than MetaValue. (So, we'd fold the code into a new module in pandoc-citeproc library, and biblio2yaml could be used for the conversion.) Thoughts? +++ Nick Bart [Sep 30 13 14:31 ]: > Note that in the patch above, > hasEditortype <- isPresent "editortype" > if hasEditortype then > opt $ do > should read: > hasEditortype <- isPresent "editortype" > opt $ if hasEditortype > then do > Apologies. > > -- > 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 pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > [1]https://groups.google.com/d/msgid/pandoc-discuss/66a61c32-a3b4-45c2- > b548-442592eab56d%40googlegroups.com. > For more options, visit [2]https://groups.google.com/groups/opt_out. > > References > > 1. https://groups.google.com/d/msgid/pandoc-discuss/66a61c32-a3b4-45c2-b548-442592eab56d%40googlegroups.com > 2. https://groups.google.com/groups/opt_out