I’m a researcher and I want to build a web page with a list of my publications. But I’m not sure what is the best way to do it…
Each publication has some author metadata (title, author names, publication date, DOI link), and most of them also have an attached PDF file. If this were a list of blog posts it would be easy peasy: Each blog post would be a markdown file, I would put the metadata in the [extra]
section in the front matter, and the section page would display the list of posts. But the PDF files make this a bit more complicated. My current solution involves a content/publications
folder with a markdown and a pdf file for each publication:
content/publications/
foo.md
foo.pdf
bar.md
bar.pdf
The markdown files have a front matter with the metadata, and a link to the pdf file.
+++
title = "On second order foo derivatives"
date = 2020-01-02
[extra]
authors = "Karl Gauss, Galileo Galilei"
pdf = "foo.pdf"
+++
But this is klunky. There are two files to keep track of; the pdf link in the [extra]
section silently breaks if I misstype it; and my Tera templates got a bit too complex.
I also explored using collocation, to avoid the need for naming the link, but I didn’t like how all the downloaded pdfs had the same name.
content/publications
foo/
index.md
paper.pdf
bar/
index.md
paper.pdf
Right now, I’m stuck not knowing what’s the best direction to go. Maybe I just need a way to know at compile-time that the PDF link in the metadata is not broken. Maybe there’s a simpler way to implement this, using fewer moving parts. How would you approach this problem?