public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* pandoc expand citation with yaml reference
@ 2019-07-06 20:28 Colin McLear
       [not found] ` <3ff393ff-c85f-4512-86ae-68af7357e86b-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Colin McLear @ 2019-07-06 20:28 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 1583 bytes --]

Hi all,

I'm looking to convert  a variety of markdown notes that have pandoc 
citations to the expanded citation plus the full reference in yaml. I can 
do parts of this but can't seem to put everything together in one 
scriptable command.

So I can get expanded citations using `pandoc -t markdown-citations 
--bibliography=path/to/bibfile.bib -s`. But this gets me a *markdown* 
reference in a reference div, and I would like a *yaml* reference, with the 
full entry information as present in the bibfile, in the div. 

 I can get yaml references by converting a bibfile to yaml using pandoc 
citeproc like so: `pandoc-citeproc --bib2yaml bibfile.bib`. 

What I can't seem to get is the conversion of a single markdown file, using 
pandoc citations and a bibtex bibfile, into a markdown file with expanded 
citations and a yaml reference block at the bottom. Is this possible? If 
the answer is 'do it with lua script' any hints on doing so would be 
appreciated -- my lua skills are rather basic. 

thanks.

-- 
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 https://groups.google.com/d/msgid/pandoc-discuss/3ff393ff-c85f-4512-86ae-68af7357e86b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 2135 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: pandoc expand citation with yaml reference
       [not found] ` <3ff393ff-c85f-4512-86ae-68af7357e86b-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2019-07-07 20:14   ` John MacFarlane
       [not found]     ` <87ftnhfvq2.fsf-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: John MacFarlane @ 2019-07-07 20:14 UTC (permalink / raw)
  To: Colin McLear, pandoc-discuss


There's no automatic way to do this in pandoc.
You could do it with a filter, sure. Or you could
do something easy like

pandoc input.txt -t markdown-citations -s -Vinclude-after="$(pandoc-citeproc -y mybib.bib)"

Colin McLear <mclearc-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> writes:

> Hi all,
>
> I'm looking to convert  a variety of markdown notes that have pandoc 
> citations to the expanded citation plus the full reference in yaml. I can 
> do parts of this but can't seem to put everything together in one 
> scriptable command.
>
> So I can get expanded citations using `pandoc -t markdown-citations 
> --bibliography=path/to/bibfile.bib -s`. But this gets me a *markdown* 
> reference in a reference div, and I would like a *yaml* reference, with the 
> full entry information as present in the bibfile, in the div. 
>
>  I can get yaml references by converting a bibfile to yaml using pandoc 
> citeproc like so: `pandoc-citeproc --bib2yaml bibfile.bib`. 
>
> What I can't seem to get is the conversion of a single markdown file, using 
> pandoc citations and a bibtex bibfile, into a markdown file with expanded 
> citations and a yaml reference block at the bottom. Is this possible? If 
> the answer is 'do it with lua script' any hints on doing so would be 
> appreciated -- my lua skills are rather basic. 
>
> thanks.
>
> -- 
> 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 https://groups.google.com/d/msgid/pandoc-discuss/3ff393ff-c85f-4512-86ae-68af7357e86b%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: pandoc expand citation with yaml reference
       [not found]     ` <87ftnhfvq2.fsf-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org>
@ 2019-07-08 13:25       ` Colin McLear
  0 siblings, 0 replies; 3+ messages in thread
From: Colin McLear @ 2019-07-08 13:25 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 2708 bytes --]

ok - thanks John.

On Sunday, July 7, 2019 at 4:14:45 PM UTC-4, John MacFarlane wrote:
>
>
> There's no automatic way to do this in pandoc. 
> You could do it with a filter, sure. Or you could 
> do something easy like 
>
> pandoc input.txt -t markdown-citations -s 
> -Vinclude-after="$(pandoc-citeproc -y mybib.bib)" 
>
> Colin McLear <mcl...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org <javascript:>> writes: 
>
> > Hi all, 
> > 
> > I'm looking to convert  a variety of markdown notes that have pandoc 
> > citations to the expanded citation plus the full reference in yaml. I 
> can 
> > do parts of this but can't seem to put everything together in one 
> > scriptable command. 
> > 
> > So I can get expanded citations using `pandoc -t markdown-citations 
> > --bibliography=path/to/bibfile.bib -s`. But this gets me a *markdown* 
> > reference in a reference div, and I would like a *yaml* reference, with 
> the 
> > full entry information as present in the bibfile, in the div. 
> > 
> >  I can get yaml references by converting a bibfile to yaml using pandoc 
> > citeproc like so: `pandoc-citeproc --bib2yaml bibfile.bib`. 
> > 
> > What I can't seem to get is the conversion of a single markdown file, 
> using 
> > pandoc citations and a bibtex bibfile, into a markdown file with 
> expanded 
> > citations and a yaml reference block at the bottom. Is this possible? If 
> > the answer is 'do it with lua script' any hints on doing so would be 
> > appreciated -- my lua skills are rather basic. 
> > 
> > thanks. 
> > 
> > -- 
> > 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-...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org <javascript:>. 
> > To post to this group, send email to pandoc-...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org 
> <javascript:>. 
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/pandoc-discuss/3ff393ff-c85f-4512-86ae-68af7357e86b%40googlegroups.com. 
>
> > For more options, visit https://groups.google.com/d/optout. 
>

-- 
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 https://groups.google.com/d/msgid/pandoc-discuss/94085d76-037b-430e-9b59-8b67479d72fa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[-- Attachment #1.2: Type: text/html, Size: 4726 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-07-08 13:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-06 20:28 pandoc expand citation with yaml reference Colin McLear
     [not found] ` <3ff393ff-c85f-4512-86ae-68af7357e86b-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2019-07-07 20:14   ` John MacFarlane
     [not found]     ` <87ftnhfvq2.fsf-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org>
2019-07-08 13:25       ` Colin McLear

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).