diff --git a/content/articles/2024-08-12-jekyll-hugo.md b/content/articles/2024-08-12-jekyll-hugo.md index f8387f8..e7415e1 100644 --- a/content/articles/2024-08-12-jekyll-hugo.md +++ b/content/articles/2024-08-12-jekyll-hugo.md @@ -60,7 +60,7 @@ with `sass-embedded` gem, and I spent waaaay too long fixing this incredibly fru {{< image width="9em" float="right" src="/assets/jekyll-hugo/hugo-logo-wide.svg" alt="Hugo" >}} When I made my roadtrip from Zurich to the North Cape with my buddy Paul, we took extensive notes on -our daily travels, and put them on [[2022roadtripnose](https://2022roadtripnose.weirdnet.nl/)] +our daily travels, and put them on a [[2022roadtripnose](https://2022roadtripnose.weirdnet.nl/)] website. At the time, I was looking for a photo caroussel for Jekyll, and while I found a few, none of them really worked in the way I wanted them to. I stumbled across [[Hugo](https://gohugo.io)], which says on its website that it is one of the most popular open-source static site generators. @@ -89,7 +89,7 @@ I have only a few strong requirements if I am to move my website: With that in mind, I notice that Hugo has a site _importer_, that can import a site from Jekyll! I run it, but it produces completely broken code, and Hugo doesn't even want to compile the site. This -turns out to be a _theme_ issue, so I take Hugo's advice and install the recommended them. The site +turns out to be a _theme_ issue, so I take Hugo's advice and install the recommended theme. The site comes up, but is pretty screwed up. I now realize that the `hugo import jekyll` imports the markdown as-is, and only rewrites the _frontmatter_ (the little blurb of YAML metadata at the top of each file). Two notable problems: @@ -111,11 +111,11 @@ I do some grepping, and have 246 such Jekyll template expansions, and 272 images #### Attempt 2: Skeleton ✅ I decide to do this one step at a time. First, I create a completely new website `hugo new site -hugo.ipng.ch`, download the `notrack` theme, and add only the front page `index.md` from the +ipng.ch`, download the `notrack` theme, and add only the front page `index.md` from the original IPng site. OK, that renders. -Now comes a fun part: going over the theme's SCSS to adjust it to look and feel similar to the -Jekyll `minima` theme. I change a bunch of stuff in the skeleton of the website theme. +Now comes a fun part: going over the `notrack` theme's SCSS to adjust it to look and feel similar to +the Jekyll `minima` theme. I change a bunch of stuff in the skeleton of the website: First, I take a look at the site media breakpoints, to feel correct for desktop screen, tablet screen and iPhone/Android screens. Then, I inspect the font family, size and H1/H2/H3... @@ -239,10 +239,10 @@ The first change I make is to the main `hugo.toml` config file: articles = "/s/articles/:year/:month/:day/:slug" ``` -That solves the main directory problem (I chose `s/articles/` in Jekyll). Then, adding the URL -redirect is a simple matter of looking up which filename Jekyll ultimately used, and adding a little -frontmatter at the top of each article, for example my [[VPP #1]({{< ref 2024-08-12-jekyll-hugo ->}})] article would get this addition: +That solves the main directory problem, as back then, I chose `s/articles/` in Jekyll. Then, adding +the URL redirect is a simple matter of looking up which filename Jekyll ultimately used, and adding +a little frontmatter at the top of each article, for example my [[VPP #1]({{< ref +2024-08-12-jekyll-hugo >}})] article would get this addition: ``` --- @@ -291,11 +291,11 @@ $ cat themes/hugo-theme-ipng/layouts/shortcodes/asciinema.html This file creates the `id` of the `