ads' corner

New Blog

New blog. Or, more exactly, new blog software.

I moved this blog from Serendipity to Hugo.


Dynamic content in static websites in Hugo

With people moving away from Twitter, mostly to Mastodon, discovering the new accounts became a problem.

For people in the PostgreSQL community I created a website which lists different social media accounts. This website is part of the “PostgreSQL Person of the Week” interview project, however the data source is dynamic, and stored in a different repository. This allows me to keep the repository for the website private, but publish the data for the social media links - this data is public anyway. The interview repository is private, because who wants to see upcoming interviews anyway? ;-)


Hugo: Count entries in Taxonomy

For the “PostgreSQL Person of the Week” interviews I’m using Hugo as static blogging engine. Part of every interview is the list of tags, which links this interview to other similar interviews. However until recently no one really knew if a tag is popular or just used in this interview. I wanted to change this, and add the tag count behind every tag.


Avoid linebreaks in Hugo shortcodes

Shortcodes in Hugo are a neat and poweful system to avoid repating the same piece of text over and over again. Let’s say I have the following text:


Public previews in Hugo

Hugo is a static templating system. It is (mainly) used to deploy websites/blogs which don’t have and need dynamic content. The content of all pages is pre-generated, and the webserver delivers files from disk (or rather from cache, once files are loaded into memory). This approach allows for extremely fast websites, as no dynamic content is generated on every request.

While I know Hugo from work, I haven’t really used it for private projects - until recently. I have started a new project where I present interviews with people behind the PostgreSQL Project - and this is perfect for a static website. Interviews don’t change, once published.