Quarto to Hugo: Preserving Figure Captions

The Problem When rendering Quarto notebooks (.qmd files) to Hugo-compatible markdown (.md files), figure captions are lost in the process. While Quarto generates proper figure captions in HTML output, for example: <img src="fig-distribution-output-1.png" width="464" height="470"> <figcaption> Figure 1: Distribution of Sample Data </figcaption> The markdown output for Hugo only includes the image with an alt text, like: <img src="fig-distribution-output-1.png" id="fig-dist" alt="Figure 1: Distribution of Sample Data" /> I tried playing with yaml options but there does not seem to be an easy fix. So here’s a javascript approach that constructs and includes captions for quarto generated figures automatically. ...

November 14, 2024 · 2 min · 301 words · Martin C. Arnold

GitHub Action: Scrape and Embedd Google Scholar Publications

Intro Maintaining an updated list of academic publications on a website can be tedious, especially if you’re using Google Scholar as your primary source. To streamline this process, we can build an automated workflow using GitHub Actions. In this post, I’ll show you how to create a system that fetches publication details from Google Scholar, formats them, and integrates them into a Hugo-based website. ...

November 3, 2024 · 9 min · 1774 words · Martin Christopher Arnold