lua-filters icon indicating copy to clipboard operation
lua-filters copied to clipboard

author-info-blocks and pdfauthor

Open twsh opened this issue 3 years ago • 11 comments

When I add this to my metadata:

author:
  - Jane Doe:
      institute: Nice Place

The resulting LaTeX file includes the following in \hypersetup: pdfauthor={Jane Doe1}, and this ends up in the PDFs author field. Is there a way to avoid the unnecessary '1'?

Here is a complete command pandoc --standalone --output foo.tex --lua-filter scholarly-metadata.lua --lua-filter author-info-blocks.lua foo.md.

twsh avatar May 06 '22 12:05 twsh

Pandoc really expects author to be string content or a list of strings. What pandoc version are you using? When I try this I get nothing for author in hypersetup, and in the author field of the pdf I get true.

jgm avatar May 06 '22 14:05 jgm

I'm using Pandoc 2.18.

I probably should have mentioned that I'm using the scholarly-metadata filter too, which is required for the author-info-blocks filter. (I will update my issue.)

twsh avatar May 06 '22 15:05 twsh

I assume the 1 is the resultant numbering for the institute you've added?

iandol avatar May 10 '22 14:05 iandol

@iandol Yes, that's my understanding. In the LaTeX file the \author is: \author{Jane Doe\textsuperscript{1}}.

twsh avatar May 10 '22 14:05 twsh

In my own scholarly metadata filter written in Ruby via Paru (here), I separate this info so the PDF metadata just contains the author names. I'm sure the same can be done for the Lua filter shared here, although it may need a change in the LaTeX template as IIRC it uses author-meta rather than author. @tarleb would be the expert on this.

iandol avatar May 10 '22 21:05 iandol

@iandol is right, the filter should be changed.

I'm considering to make bigger changes, too. Quarto is set to introduce a system that's similar to the one we have here, but cleaner and a bit more principled. I'll likely change the filter to use their schema, but may keep some of the current behavior for compatibility.

tarleb avatar May 12 '22 09:05 tarleb

@tarleb -- yes I saw Quarto was going to support academic metadata too, it would be great to standardise (or if they are open source, to fork and save you some effort?) and thank you for your original filter which I think provided a good base for Quarto's devs to build from!

iandol avatar May 12 '22 15:05 iandol

There's a good chance that the Quarto filter will be published as a separate filter within the next weeks. I'll deprecate my filter if/when that happens.

I currently don't have the resources to work on the filter, so I have to ask everyone to be patient for a little longer.

tarleb avatar May 20 '22 07:05 tarleb

@tarleb Thanks for letting me know about Quarto.

twsh avatar May 20 '22 09:05 twsh

There's a good chance that the Quarto filter will be published as a separate filter within the next weeks. I'll deprecate my filter if/when that happens.

I currently don't have the resources to work on the filter, so I have to ask everyone to be patient for a little longer.

Hi @tarleb , any updates on the quarto adjustments? If you need help, maybe I could also have a look on this! I also tried to adjust scholarly-metadata and author-info-block for quarto, but no success so far. It would be really really great to have these working with quarto / docx.

kapsner avatar Dec 11 '22 06:12 kapsner

@kapsner No updates yet, life interfered. I'd be grateful for any help. Feel free to message me with any question, or if you'd like to schedule a short call.

tarleb avatar Dec 11 '22 08:12 tarleb