So I used to read Joel On Software quite a bit. A few posts stand out, but one in particular is Making Wrong Code Look Wrong for a few reasons: the problem Joel describes is real, it’s subtle, and the proposed solution is elegant and trivial. Now I’m not going to claim I’m disciplined enough to actually follow it all the time – especially since most of my projects start off as toys where it’s easy enough to keep things right – but I love the idea in theory.
Continue readingNachobox Round 2 — Jenkins Automation
Last time, I had my services up and running but only with the bare minimum configurations; it’s time to put them to work.
Continue readingSetting up a Private Jenkins and Git Server
I found myself in a bit of a conundrum the other day. I’ve been using Jenkins on my laptop for a while, and it’s worked great, but I thought it’d be neat to turn one of my Raspberry Pis into a slave and get cross builds working. The problem though, is that I take my laptop with me to work and when I travel, and that means I’d have an offline build slave more than I’d like. I’d have the problem in reverse if I turned the Pi into the Jenkins master, but there was another problem: I’m addicted to Gentoo, and they don’t have Jenkins available for arm machines via portage.
The solution was obvious: set up another system that I could use as a Jenkins master that’d reliably be able to send jobs to the Pis. And, so long as I’m going to do that, I might as well get Gitea running on the new box.
Continue readingThinking With Tasks
Up until now, all dependency ordering in dev-pipeline is managed using a function that provides a valid sequence as a Python list. The simplified code is basically this:
build_order = resolve(self.targets, self.components)
for target in build_order:
for task in self._tasks:
task(target)
This has been fine for initial versions, but it’s not very flexible.
Continue readingdev-pipeline 0.3.0a0 Available
So my project management software has a new alpha release. Originally this version was just going to have a few small features that a friend needed for his use-cases that required changes to core functionality (his front-end doesn’t require anything akin to a configure step).
The specific features I wanted to support for 0.3.0 were:
Continue readingStep 2 — Scratching Everybody’s Itches
So I had dev-pipeline in a position where it met every one of my current needs: I could fetch sources, I could build, and I could generate dependency graphs. I was happy and my projects ran well.
Continue readingNaming Conventions Need to Add Value
Naming conventions: the only aspect of code formatting more contentious than where to put your braces (for the record, braces go on a new line). We all have our favorites, and anybody who doesn’t comply is an idiot. Not a regular idiot either like the person who says cut and paste when they mean copy and paste, but a major idiot like that guy in the office who can’t figure out how to Google error messages (we all know one).
So here’s the big question: how do you know your naming conventions are right?
Continue readingStep 1 — Scratching Your Itch
Every good work of software starts by scratching a developer’s personal itch.
Eric Raymond, The Cathedral and the Bazaar
Like most developers, I’m a creature of habit. I like git for source control, so I use git to track changes in pretty much everything, even if they’re non-source (e.g., configuration files, my resume, and even my hobbyist writing). It’s mostly a matter of sticking with patterns I know and embracing muscle memory; with git not only get version tracking, but I can easily back my work up to tons of places with one command.
Continue readingManaging Complex Projects
A while ago I mentioned dev-pipeline, and I kept hacking away and improving the software. I didn’t think about it too much since it met my needs (or was easy to add the missing feature), but it came up at work the other day and I decided to see just how complex the project I was managing was. Since dev-pipeline learned how to generate dependency graphs in dot format, this was easy.
Continue readingModernizing C++ Interfaces
Let’s assume a project has to transform data from one form to another; this could be updating a configuration file during a software update, loading XML to store into a database, or any of the other million things that this problem applies to. For the sake of simplicity, we’ll assume the theoretical project needs to convert strings from mixed-case to uppercase.
Continue reading