Shitty first commits

I've been writing this blog for a little over a month. Writing, it turns out, is really hard. Ideas are a dime a dozen, but trying to write something interesting for someone else to read brings about cold sweats, heavy breathing, and suicidal thoughts. Luckily for me the nearest bridge is 15km away and I'm very, very lazy.

Coding shares many parallels with writing. Coming up with an idea for an app, a game, or a website can be easy, but trying to create something that people need saps the enthusiasm out of even the most diligent programmers.

What starts out as the best-idea-yet soon becomes the worst-thing-ever. You begin doubting your ability as a programmer; you wonder if the framework you've chosen is the right one; you fear what real programmers will think when they see your code. Suddenly, you can picture them, pointing and laughing. They tell your boss, your family and friends. Before you know it, you're jobless, homeless, and nobody loves you anymore.

To save yourself the heartache and humiliation, you convince yourself that at the moment there isn't enough time because, well, you're really busy. The best-idea-yet gets added to the pile of unfinished projects.

This fear isn't entirely self-made. Developers by nature focus on the logic and structure of code, often ignoring the person behind it. In A Million Lines of Bad Code, David Robinson suggests that programmers should take into account the million lines of bad code they've written before judging others' code, which I think is great advice. He also makes the analogy to writing:

There’s a popular piece of writing advice that has many variations, but usually goes something like: "Everyone has a million bad words in them. Only once they’ve written those million words can they start writing well. So get writing!"

This reminds me of one of the best non-fiction, non-programming books I've ever read: Bird by Bird: Some Instructions on Writing and Life by Anne Lamott. I love it so much I own a hardcover first edition!

Anne Lamott introduces the idea of the shitty first draft:

Now, practically even better news than that of short assignments is the idea of shitty first drafts. All good writers write them. This is how they end up with good second drafts and terrific third drafts [...] Almost all good writing begins with terrible first efforts. You need to start somewhere. Start by getting something - anything - down on paper.

One of the reasons for ever growing pile of unfinished projects is the plague of perfectionism. Driven by fear, we want the code to be perfect. Anne Lammott covers this as well:

Perfectionism is the voice of the oppressor, the enemy of the people. It will keep you cramped and insane your whole life, and it is the main obstacle between you and a shitty first draft. [...] Besides, perfectionism will ruin your writing, blocking inventiveness and playfulness and life force (these are words we are allowed to use in California). Perfectionism means that you try desperately not to leave so much mess to clean up.

When starting a project we're working on our shitty first commits. These are our first steps in a new world, a recording of our first words. When a baby begins to babble we don't ridicule it for not quoting Shakespeare, we understand that it's learning. It's the same for programmers.

Rather than pressue yourself into producing something perfect, accept that you're learning and that the process of shitty first commits is required for you to reach your goal.

Author image
Creator of Humble Coder and serial hobbyist