Syntax highlighting in Hugo with Highlight.js

I wanted syntax highlighting in Hugo for code snippets, and I wanted it fast. I didn’t want anything complicated on the server like Pygments. Among the solutions suggested in the Hugo documentation is Highlight.js. Briefly, Highlight.js uses Javascript to render things between <pre><code> and </code><pre> with the kind of syntax highlighting you expect in your favorite code editor. Here’s how I made it happen. In the /layouts directory in your Hugo installation, create a directory called /partials, and in that directory create a file called header.

Read More

Is this Gibson Les Paul guitar worth $131,000?

I know that guitars like this 1957 Les Paul goldtop selling on Reverb can command prices like the $131,000 this instrument’s owner is asking. But the condition of the instrument isn’t anywhere near what it should be, and absent a compelling story like somebody super-famous owning and playing it, I can’t see it selling for anything near this price. I’m no expert on vintage Les Pauls (I can tell you a lot more about what vintage Gibson archtops should cost), but this looks to me like the owner wants somebody to offer $50,000.

Read More

Back to Hugo in 2017

I’m giving Hugo another try. I had a problem with Hugo version 0.18 and the redlounge theme: All of my categories and tags were being listed in the blog index, which doesn’t look so good. I tried changing themes: I used hyde, and the unwanted index entries magically went away. But I like redlounge, so I did some experiments with the configuration. In my config.toml file, I went from: [taxonomies] tag = "

Read More

Hugo 0.18 weirdness

Since it’s so easy to upgrade Hugo (grab new binary, copy into /usr/local/bin… and that’s it), I upgraded to version 0.18 yesterday. I rebuilt my still-super-small site. Yes, everything was faster, but I ended up with extra entry-style … entries? … on my index page for all of my categories and tags … plus a couple of “entries” that 404’d out. Not wanting to untangle it (and preferring to let the Hugo experts discover and deal with it at this point in my use of Hugo), I rolled back to 0.

Read More

Is Hugo worth it?

The question I’m asking myself as I resurrect this Hugo site: Is it worth it? Static site generators are geeky, the language used to code Hugo – Go (aka golang) – is somewhat obscure (i.e. it’s not Javascript, Ruby or Python), and did I say it’s not done in Javascript? Yep, did. Worth mentioning twice. I could look for a Javascript/Node-driven static blog generator, I could use the Python-based Pelican or Ruby-written Jekyll.

Read More