Useful Consumer Review

All Emacs users, at one point or another, feel like they need a pedal to get all the keystrokes in. But now I could actually use one: I’ve got a blogging project that requires using a scanner, and triggering that with a foot would mean less bending to reach the keyboard.

So I got an iKKEGOL USB Foot Control Action Switch Pedal and was excited to see just what obscure HID keycode it’s generating. (These things usually pretend to be keyboards, which makes for easy integration without any drivers and stuff.)

So I connect the pedal and start up xev and:

“b”? It sends “b”!?! “b”!!!

OK, I can work with that for the scanning thing, but “b”!?!?

“b”!!!1!?

Totally Epic

I don’t really have time for this, but I’ve started blogging about yet another 80s comics publisher: Epic Comics.

Or rather “publisher”: It’s an imprint of Marvel Comics, but was initially running as a somewhat separate entity within the Marvel offices.

Don’t expect very frequent posts. Or at least not to begin with, as the initial batch of things Epic published included series that went on for quite a while, which means that I have to read thousands of pages to blog about them.

But if you’re interested: Here’s the link to the Totally Epic blog.

NFLX2019 November 15th: Klaus

Klaus. Sergio Pablos. 2019. ☆☆☆☆☆★

This is super sweet. It’s told in a brash, irreverent tone, but it’s a very sentimental Christmas movie about Santa Claus and stuff. If you’re easily moved, it’s full of really touching scenes throughout: It’s amazing that they keep delivering these highly emotional punches time and time again.

And the animation is really fun to watch.

So: Sweet, funny, pretty, touching. It’s a new Xmas classic.

This post is part of the NFLX2019 blog series.

NFLX2019 November 8th: Earthquake Bird

Earthquake Bird. Wash Westmoreland. 2019. ☆☆☆★★★

Man, this is a mess. I was totally on board thinking this was a really interesting movie, where ever shot had a deeper meaning. We were all “oh, this means she can see dead people! No, she’s a vampire! No, she’s dead!” but calm down: There’s no Shyamalaning going on here:

The resolution to this movie is the most boring possible thing and will make you go “really? really!? Because that’s not a twist!”

Dude.

But I loved the colours here. The actors are great and it’s all very very pretty. Was this sponsored by the Japanese tourist board or something?

So in conclusion: It’s a very stupid movie that pretends that it’s smart, and that’s not ultimately fun to watch.

This post is part of the NFLX2019 blog series.

Adding a CSS File to WordPress

Of all things in the world that are frustrating, Googling for how to do things in WordPress is the absolute worst.

I guess I’m not used to, like, search for stuff that’s popular. Because whatever you search for related to WordPress, the top ten answers are from content farms that wants to sell you something, and in addition to being sleazy, their answers are all wrong.

So you have to resort to The Dark Web (i.e., page two of the Google search results) before you get to something that seems to half-way make sense… and then it doesn’t. Not really.

OK, here’s my issue: I wanted to edit the CSS of a WordPress site with Emacs. Because editing the CSS in a text box in a browser is miserable, horrible and no good. If you Google this, you’ll find out that there’s a bunch of plugins that… allows you to edit the CSS in a text box in a browser.

I just want a file somewhere! That I can edit!

So, on the Dark Web, I found somebody with a solution: Just put the extra code in the theme! Or put the code in functions.php! But won’t those changes be overwritten when WordPress is upgraded? Sure!

*sigh*

So after going to The Even Darker Web (page three), and putting four different answers together, I now have a sustainable solution: CSS in a file, loaded in a way that won’t be overwritten when you upgrade WordPress.

Here’s how. Create the directory /var/www/html/wp-content/plugins/site-css. Put the following in the file site-css.php inside that directory:

<?php
/*
Plugin Name: Site CSS
Description: Site specific CSS
*/

function add_custom_css() {
  wp_enqueue_style("site-css", "/wp-content/plugins/site-css/site-css.css");
}

add_action("wp_enqueue_scripts", "add_custom_css");

Go to the WordPress admin panel, and choose “Plugins”. You’ll see a new plugin there called “Site CSS”. Activate it.

That’s it! You can now edit the file called /var/www/html/wp-content/plugins/site-css/site-css.css to your heart’s delight via Tramp in Emacs and tweak those little rounded CSS corners until they look… just… right:

Did you find this blog on page seventeen in Google? You’re welcome!