From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matt Price Subject: Re: org-cite and org-citeproc Date: Tue, 16 Jun 2015 15:36:39 -0400 Message-ID: References: <87twx5hs2x.fsf@berkeley.edu> <87wq1u7clv.fsf@gmail.com> <87k2xue8gm.fsf@berkeley.edu> <87vbh9nl91.fsf@berkeley.edu> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11c235f67bc85e0518a7b124 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46380) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z4wf5-00026Z-N8 for emacs-orgmode@gnu.org; Tue, 16 Jun 2015 15:36:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z4wf3-0007Gy-Nw for emacs-orgmode@gnu.org; Tue, 16 Jun 2015 15:36:43 -0400 Received: from mail-la0-x22a.google.com ([2a00:1450:4010:c03::22a]:33401) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z4wf3-0007Gi-9s for emacs-orgmode@gnu.org; Tue, 16 Jun 2015 15:36:41 -0400 Received: by laka10 with SMTP id a10so18430956lak.0 for ; Tue, 16 Jun 2015 12:36:39 -0700 (PDT) In-Reply-To: <87vbh9nl91.fsf@berkeley.edu> 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-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org Mode --001a11c235f67bc85e0518a7b124 Content-Type: text/plain; charset=UTF-8 On Mon, Apr 6, 2015 at 2:51 PM, Richard Lawrence < richard.lawrence@berkeley.edu> wrote: > Hi Aaron and all, > > Richard Lawrence writes: > > > Alright, I'll try to move to json.el, and possibly change to having > > org-citeproc generate Org markup in the meantime. > > Just a heads up: I've pushed some changes to my branch of Org to make > org-cite use json.el, and to add a basic Org format writer to > org-citeproc. > > I have not made any other changes to org-cite to use the Org formatted > output from org-citeproc, though, as I believe doing this properly will > involve parsing the output and inserting it into Org's exporter's parse > tree (to accommodate the bibliography and note-based styles). I won't > have time to work on that this week, but I'll come back to it. > > Best, > Richard > > Hi Richard et al, I'm wondering what kind of work is required to make use of org-cite and org-citeproc at present. In particular, I'm wondering what kinds of changes I'll need to make to my current setup, and whether it's worthwhile to use my ultra-slow coding skills to create whatever glue is still necessary. Here's my setup at present: I currently use Zotero for most of my bibliography management; it's relatively easy to get zotero to export a bibtex bibliography (cf. https://github.com/robintw/AutoZotBib), and I will switch to bibtex if absolutely necessary. I'd rather just keep using Zotero, though. I use zotxt-emacs to insert references in org files. I export my work to html and odt. I use this small bit of code to manage exports: ;; zotxt (org-add-link-type "zotero" (lambda (rest) (zotxt-select-key (substring rest 15))) (lambda (path desc format) (if (string-match "^@\\(.*\\)$" desc) (cond ((eq format 'latex) (format "\\cite{%s}" (match-string 1 desc))) ((eq format 'md) desc) ((eq format 'html) (deferred:$ (zotxt-get-item-bibliography-deferred `(:key , (substring path 15))) (deferred:nextc it (lambda (item) (plist-get item :citation-html))) (deferred:sync! it))) ((eq format 'odt) (deferred:$ (zotxt-get-item-deferred `(:key , (substring path 15)) :248bebf1-46ab-4067-9f93-ec3d2960d0cd) (deferred:nextc it (lambda (item) (plist-get item :248bebf1-46ab-4067-9f93-ec3d2960d0cd))) (deferred:sync! it))) (t nil) nil)))) currently this grabs a full html citation and pastes it into the html export, while for odt it produces strings of the form { | Herzig, 2006 | | |zotero://select/items/0_SKDIF737}, which Zotero can understand withthe aid of an RDF/ODF scan plugin. All of this is fine for my current purposes, but I would like to figure out a more flexible and enduring solution, so I'd like to try out org-cite and org-citeproc. But I'm not quite sure what's required, and whether there's support currently for odt and html export. Thanks very much for your help, Matt --001a11c235f67bc85e0518a7b124 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: base64 PGRpdiBkaXI9Imx0ciI+PGJyPjxkaXYgY2xhc3M9ImdtYW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