The Liskov Substitution Principle applies to any OOP language. On the surface it is a structural principle, but its true lesson is concerned with behaviour.
SOLID: The Open–Closed Principle (OCP)
The Single Responsibility Principle is harder to grasp than its name implies, with a history of misleading definitions. We're going to be pedantic about the definition right out of the gate, to ensure we come away with the right understanding.
SOLID for Ruby Engineers
•
4 min read
The SOLID principles are required learning for software engineers dealing with object-oriented code. Think you know them? Let's take each one apart together.
Your Dependencies Are Not Free
•
5 min read
Dependencies are free chunks of functionality, except when they're not. They come with hidden costs which need careful consideration.
Start a Blog With Ghost & PikaPods
•
13 min read
Start writing now with a Ghost blog on PikaPods! This guide takes you through all the steps for a production-ready Ghost install, complete with newsletter support.
Complexity
•
8 min read
I dislike [all] blanket statements, but complexity is never desirable.
Managing complexity is the most important technical topic in software development.
In my view, it’s so important that Software’s Primary Technical Imperative has to be managing complexity.
— Steve McConnell, 2004
It must have been around 2008 that I
Remove the 'Choose Your Search Engine' Dialog in Capybara
•
1 min read
Google recently added a dialog to let users select their search engine. Ordinarily you choose your preferred search engine and get on with life, but this doesn't appear to be the case when using Chrome for automation, such as through Capybara; everything is fine if running in headless
A Better Gitconfig
•
4 min read
Git provides a rich set of options for customising its behaviour via the .gitconfig file. I present here some of the more interesting options.
For more comprehensive information on each and every option, you had better peruse the official documentation.
Basics
Depending on your preferences, the global gitconfig file is
Eleventy Tricks
•
4 min read
I recently moved this site away from Hugo and onto Eleventy. Given my simple needs, I was attracted to Eleventy because it too is simple and flexible. Unfortunately, those very positive traits mean that developers may need to invent a few features for themselves — one size does not fit all,
My App is Slow. Who Cares?
•
2 min read
It's not a rhetorical question.
Who, and why, do people care if your app is slow? What is the purpose of the code you're writing? Whom does it impact? And where is the author going with this?
Today I came across a post on social media
Debugging Software and Coffee
•
3 min read
Our coffee machine is currently at the shop for repair, so we're stuck drinking instant. It's not fantastic, but it's really all right in a pinch. In fact, my parents exclusively drink instant because it's what they're used to — seems
RubyMine with Docker
•
6 min read
Lately I've been experimenting with RubyMine. I've played around with it in the past, but always ended up back on vim for various reasons. This time I'm making a concerted effort to learn its feature set and make them work for me, and so
Faster Excel Parsing in Ruby
•
2 min read
When exporting data for general use, we commonly reach for CSV files; they're basically plain-text, but with a sort-of agreed-upon structure — well, there is RFC 4180 but Wikipedia agrees that implementations are inconsistent at best.
For the layperson, though, Excel sheets are what's used and understood.
Powering a Windows PC via HomeAssistant
•
5 min read
I have a PC hooked up to the TV in our living room, which is used primarily for Kodi and video games. I'm using a Logitech Harmony activity to switch the TV on, power the AV receiver, change to the PC input, etc. The only problem is that
Sidekiq and Logrotate: Why Is My Disk Usage Increasing?
•
1 min read
One of our servers recently experienced an issue in that its disk usage was consistently growing to illogical, unmanageable proportions. This would trigger an OpsGenie alert and wake me up, so in a groggy state I'd delete some extraneous log files (we log a lot), promise myself to
Testing APIs in Ruby with RSpec
•
5 min read
Testing API calls is a little bit hairy. We can assume that the API will return the results specified in their documentation, but we'd still like to see what our API client returns; this may differ considerably from what the API itself gives us.
The last thing we