Site

Posts where something interesting happened with the site itself.

I have one like somewhere

I have one like somewhere

Been meaning to get webmention integration for a while. Went the easy way, using webmention.io and brid.gy. Easier than writing everything myself.

For now it’s just like counts, with a Invoke task checking my mentions feed at Hugo build time. More stuff is planned, but first I decide how much information to show and from which sources. Not every tweet reply is intended as a blog comment.

Python Invoke

I got to know the Python invoke task runner a little better.

Read on…

Stealing a Hugo Shortcode for Nikola

Stealing a Hugo Shortcode for Nikola

I needed a YouTube shortcode for Nikola, so I adapted Hugo’s.

Read on…

Yay Fluid Images

Yay Fluid Images

Fluid images in my posts, with added ![]() accepted syntax for the markdown content! This Hugo community post covers the details.

Amusingly, I’m doing this to make it easier to convert to another system. Other site generators know what to do with standard image markup, as opposed to my custom shortcode. The key for the Big Rewrite is to keep working on what you have now. That way the Big Rewrite isn’t quite so big.

Somebody Discovered Fork Awesome

Somebody Discovered Fork Awesome

I already forget how I bumped into Fork Awesome. It was like a whole hour ago.

And yep. Still working on the Nikola port as time permits.

inv note

inv note

$ inv note --title='inv note'

Don’t mind me. I’m just trying an experiment with using Invoke for my site workflow instead of Make.

$ inv serve
SHOW_INFO=1 hugo server --buildDrafts --bind 0.0.0.0 --navigateToChanged
...
Press Ctrl+C to stop

But that’s boring on its own. Here. Have a drawing.

I’ll probably make a proper blog post about Invoke later. Meanwhile, checkout the docs on Getting started.

$ inv publish
Added dark mode for the site

Added dark mode for the site

Got tired of blowing my eyeballs out during evening work.

How? I used prefers-color-scheme. It tries to respect existing light/dark mode settings. Here’s the stylesheet short version.

:root {
  --text-color:                 hsl(0, 0%, 0%);
  --content-background-color:   hsla(0, 0%, 100%, 0.8);
}

@media (prefers-color-scheme: dark) {
  :root {
    --text-color:               hsl(0, 0%, 100%);
    --content-background-color: hsla(0, 0%, 0%, 0.8);
  }
}

#page-content {
   background-color: var(--content-background-color)
   color:            var(--text-color);
}

Choosing a static site generator

If you’re making a site for fun, use something you’ll have fun with

Read on…

Tweaking a Nikola Theme

Tweaking a Nikola Theme

Read on…

Random Geekery a la Gatsby.js

Random Geekery a la Gatsby.js

Finished the Gatsby.js tutorial. Thought I’d dump the live site’s content into the tutorial site. Fiddled a little bit with gatsby-image. (It ignored the RST files, but that’s okay.) I never did change the title.