Git in a nutshell: Commit, Checkout, Reset

We’re going to talk about three basic git commands in this episode: commit, checkout and reset. Instead of making up any abstractions or metaphors, we will focus straight on how these commands modify your repository’s internal state. [Read More]

3 Practical Uses of void Pointers in the C Language (part 1/3)

Probably every beginner’s book on C programming has a section on pointers. Usually, there are also one or two paragraphs on the topic of void pointers. Have you ever asked yourself what they can actually be used for? In this article, we will explore some practical uses for pointers of... [Read More]

Embedded Programming: Loose Coupling Best Practices (Part 1/3)

When creating Embedded Software, system complexity that grows over lifetime makes it increasingly harder to reason about certain behaviors of the program. As always in engineering, it helps to divide one big problem into several smaller problems in order to be able to eventually solve it. This is what this... [Read More]

Git: Compare feature branches to master (Part 2/2)

In the previous article we’ve seen how to ask Git for changes introduced by a particular branch. This time, instead of changes, we would like to know which commits were introduced by a branch – that is, the hashes assigned to them. [Read More]

Debugging on the Command Line

Do you use a GUI debugger? Chances are that it is backed by the GNU Debugger, gdb, somehow. Wouldn’t it be great to use that backend directly? In this article, we are going to highlight some strengths of gdb’s command-line interface over GUI frontends. [Read More]

Stand-alone TDD monitor using 'entr'

Have you ever thought of something that continuously monitors your project’s source tree and triggers a unit test build upon file changes? You want it to be independent of the editor or IDE you use? Then maybe this is for you. [Read More]

Fixing Typos while Writing -- Two Ideas

Here are some thoughts on text editing. No matter what kind of text you write – source code, articles, to-do lists, books – there’s always a chance you get a single letter wrong at one point. Depending on your touch typing skills, this might not happen very often. But when... [Read More]

C Bitshift Operator Revisited

Recently someone asked me about C’s bitwise shift operator, specifically about what it does to signed integers. To be honest, until then I haven’t even considered applying the left or right shift operator to anything else than unsigned numbers. So let’s figure out what this is about. [Read More]

Undo Feature Using Git Plumbing Commands

Have you ever thought about adding an undo feature to your application? This blog article is an attempt to approach that task by utilizing some internals of the Git version control system together with the Memento design pattern. But please, don’t take this too seriously :-). [Read More]

Hex Parser

This article is about creating a parser for HEX files, a format that is often used as an intermediate step for programming microcontrollers. Although there are – of course – implementations out there already, I would like to use this as a welcome opportunity to play around with some interesting... [Read More]

From Subversion to Git: Snapshots

What does it mean that we talk about snapshots of our Git repository, while in Subversion we think in terms of file changes? For me at least, the key to understanding Git is that every commit is, in fact, a snapshot of the entire project. Not a list of patches.... [Read More]

Bash Job Control

When working on the command line, you may sometimes find yourself in a situation where you’d like to start a new program while another long-running process (e.g. an editor) is blocking the current terminal. In the course of this article we are going to find out how to achieve quick... [Read More]

Introduction To Readline

When developing command line applications, you will most certainly want to have bash-like line-editing features. For that, an excellent choice is the GNU readline library. We will see in this article how to use its features from out own programs in order to provide a user experience similar to that... [Read More]