Goodbye Pelican, Hello Quarto


February 20, 2023

Where it All Started

Seven years ago, I first published a Jekyll blog hosted in Github pages and let it lie largely dormant for two years. Then, as a New Year’s resolution, I rebuilt the entire thing using Pelican so I could stop using Ruby and, finally, fully transition all my personal code projects into Python.

It’s been five years since that blog post, and in that time I’ve published only 13 post on this blog. That’s less than three posts a year.

That’s kind of sad.

Starting Over

In the years since I began on that resolution to write more and educate on Python, I found myself struggling to generate new content. Not for a lack of ideas, but from a combination of excuse making (classic procrastination) and technical barriers that made publishing content less than streamlined.

The way the Pelican based blog was setup required some complexity with a multi-repo setup. One for the source markdown files and one for the html output.

This required the use of git submodules and memorization of Pelican commands to generate the content. I forgot them often enough that I ended up using the README of the source repo to add notes for myself so I wouldn’t forget how to publish.

Soon, I was looking to write more content that included not just blocks of example code but also their output and Python notebooks seemed like a good way to go about that. However, integrating them into Pelican became a journey all of it’s own. I stumbled across the pelican-jupyter library and first things were great. Suddenly I could mix markdown and python code and publish to my blog, but the fun stopped soon enough. The package depended on nbconvert to convert the notebooks into the html needed for publishing but a version upgrade broke the dependencies and soon even pinning the older version no longer solved all the conflicts; as other packages quickly required newer versions while the package was unable to keep up.

I started looking for a better way to publish python notebooks as a blog and stumbled across Quarto. After reading through the docs, I was blown away. How long had this been around? This was everything I needed and more.

Better Than Ever

Before long I had a proof of concept stood up in parallel and was able to not only publish without any archaic commands but I could render previews locally in VS Code, eliminate the need for a second repo, and the themes and layouts were based on simple bootstrap. The current look and feel is a bit more basic, but the focus is more on the content and there is even a built in search tool.

Even better, they had explicit directions for publishing to Github Pages using Github Actions. This made it easier than ever to write content and publish withough worrying about the static site generation. In fact, I could even write markdown directly in Github (in the browser) and commit to the repo and the publish action would immediately deploy to my site! So cool.

Suddenly, Github was my personal blog CMS without any need for a database or admin site. Just simple git commit.

Now I have one less excuse to start writing more and much more functionality to play around with. I’m very excited about exploring more interactive data viz using Observable and the ability to switch between R and Python as I collaborate with some of my colleague who prefer to code in R, like Chris Haid.