I never thought too much about the commit messages I write. There’s the obvious idea of writing clear messages, much like writing a good headline for a blog post or a good subject line for an email. Otherwise, I did whatever made sense.
Many years ago, I remember learning about CVS and version control in general. I didn’t start using it until I learned Subversion, and eventually I switched to Git.
As a primarily lone wolf indie game developer, I don’t think too much about how other people might read my source repository. I think about how I might use it, and my repo is mainly a place to make sure that major mistakes aren’t going to cost me a ton of time to figure out how to revert.
Basically, the evolution of my project is bookmarked at key points along the way. As I write more code and find I introduced a problem, I can check the diff to see how I did so. If I can’t figure it out, I have the option to throw away what I’ve done and start from a known state.
It works better if I bookmark my progress frequently and not have large commits containing what is actually a bunch of different changes.
And frequent bookmarks mean that I can give concise yet specific names to those bookmarks. I think I’m pretty good at naming what I’ve just done.
But then I found How to Write a Git Commit Message by Chris Beams, and I like what he had to say on this topic.
First, there’s the idea of the context of the change. At my day job, I think the issue I flag most often in code reviews for my teammates is naming their tests, variables, and functions in a way that gives context to what they’re doing. I especially hate test names that essentially tell me what the code already tells me.
WhenFooIsClickedThenCouponCode3IsCalled is not a good test name because it doesn’t tell me why. It just tells me what a reading of the code would tell me. What is calling CouponCode3 supposed to accomplish? THAT’S the thing that I want the test name to tell me.
WhenFooIsClickedThenItemIsPurchasedWithEmployeeDiscount would be much better. It does so by using the CouponCode3 function, which is also terribly named in this contrived example so fix that issue, too, please.
When it comes to commit messages, I see similar naming problems, but I haven’t thought much about it. But if you’re looking for a previous change, which is better:
Fixed crash bug
Fix crash when handling sprite rotation
Obviously the second one communicates more context. If I had to read through commit logs to find a past change, I want more commit messages that read like it.
He provides 6 other tips, and one of them is to write your commit subject line in the imperative.
It’s the reason why I found the article in the first place as this tip was shared on Twitter:
A properly formed git commit subject line should always be able to complete the following sentence:
If applied, this commit will your subject line here
If applied, this commit will refactor subsystem X for readability
If applied, this commit will update getting started documentation
If applied, this commit will remove deprecated methods
If applied, this commit will release version 1.0.0
If applied, this commit will merge pull request #123 from user/branch
Notice how this doesn’t work for the other non-imperative forms:
If applied, this commit will fixed bug with Y
If applied, this commit will changing behavior of X
If applied, this commit will more fixes for broken stuff
If applied, this commit will sweet new API methods
A lot of the article deals with writing entire bodies for commit messages. Other than maybe having a separate line to indicate who reviewed the code at the day job, I’ve never found a need to write more than a one-liner for my own projects. It would be overkill to expect myself to give that much context to myself.
But I’ve otherwise been winging it up until I read this article, and the general style guidelines make sense to me, so I’ve started to adopt it.
Here’s some commit messages from early on in my raking game project:
- Android seems to not truly restart app; clear containers on startup.
- Changed to higher resolution; using brighter 3rd-party grass sprite.
- Added damping factor to individual entities to allow for custom friction.
And here’s some recent ones:
- Provide background for Ultimate Item speaker image.
- Fix weather generator so Stormy days result in Windy days more often.
- Warn player when yards are filling up with too many leaves.
They could still be better, but keeping in mind the imperative style and finishing that sentence above means my commit messages are more consistent, which makes it easier for me to write them in a way that gives context to what the change is doing and makes it easier for me to read them later when I am trying to find the one past changeset that is relevant to whatever I am working on at the moment.
One of the things we’re taught to believe as American citizens is that we cherish our freedoms and our rights. Life, liberty, and the pursuit of happiness. Freedom of speech. Freedom of religion.
And if we’re accused of a crime, we get to face our accusers and have a fair shot at defending ourselves. It’s in the base Constitution, and in the 6th expansion pack it even says “In all criminal prosecutions, the accused shall enjoy the right to a speedy and public trial, by an impartial jury of the state and district wherein the crime shall have been committed.”
We’re presumed innocent until proven guilty.
We’re taught, “Look at THOSE countries. The oppression by the government, the jack-booted thugs executing people without trial or with sham trials where the deck is stacked against the accused. We have it much better here.”
We Americans have it good, right?
But some of us don’t.
In fact, many of us look the other way when again and again and again and again the police carry out executions against people of color. We look the other way when it happens in broad daylight. We look the other way when there is video footage showing it happening.
Somehow, even when the evidence says, “You can’t look the other way”, we find a way to look the other way.
It doesn’t matter whether or not the victim is a teenager or a grown adult. It doesn’t matter if the victim was a model citizen or had a colorful past. It doesn’t matter if the victim was fleeing or standing or sitting or had his hands up.
It doesn’t matter, because if we are being accused of a crime, we as Americans expect to be able to defend ourselves before we’re found guilty of the crime. In court. With a fair trial.
To stand that trial, we expect to be alive. We should NOT have to worry that our lives are forfeit just because someone suspects we might be bad guys.
Worrying that the government will bring about my death if I breathe wrong when accosted by police is not how it is supposed to work in this country. That’s for other, lesser countries with totalitarian governments.
And yet, we live in a country where some of our fellow citizens are not being afforded the right to a trial by jury.
We live in a country where some of our fellow citizens are being told that the basic rights guaranteed by the third article of the Constitution and the 6th amendment do not apply to them if a police officer decides to act as judge, jury, and executioner.
We live in a country that has tolerated actions that we are supposed to look down upon.
So what kind of country are we living in?
Because the totalitarian-type actions happen predominantly to Black people, we ignore them. We justify it by looking for reasons why they got themselves killed by police officers, people who after all have a tough job and risk their lives to keep us safe.
As a White male, I live in a completely different America. My America looks a lot like the one I was taught about growing up.
And because of my White privilege, I can look the other way when there is too much cognitive dissonance. When what I want to believe about America and what the daily experience and death toll for Black people in that same America are at odds, I can choose to say, “No, I live in the greatest country in the world, so it must be something else that’s going on.”
I can stay silent when I witness what happened to Philando Castile.
I can stay silent when I witness what happened to Alton Sterling.
I can stay silent when I witness what happened to Eric Garner.
To Michael Brown.
To Tamir Rice.
To Eric Harris.
To Samuel DuBose.
To Freddie Gray.
To Walter Scott.
To Laquan McDonald.
I can stay silent, because it doesn’t happen to me.
After all, I live in a completely different America in which I don’t have to fear being executed by a police officer for a routine traffic stop.
I live in a completely different America where even if I was violent and a threat to the people around me, and even if I killed officers trying to detain me, I could be sure that I would be arrested, alive, and ready to stand trial.
Executions in the streets? They only happen in other countries.
Including that other America I can pretend doesn’t exist.
Because Black people are being regularly harassed, beaten, terrorized, and executed by police officers, and because those actions get covered up often enough by those same police officers, there is a movement called Black Lives Matter.
Because in this America, it’s clear that they don’t matter to the majority of Americans.
Because if Black lives really mattered in America, we wouldn’t be silent about the injustice of death sentences being metered out by police without a trial. We wouldn’t keep saying, “Keep calm. Let’s wait for all the facts,” while simultaneously reaching for tenuous justifications and defending the indefensible.
It doesn’t matter whether or not the victim was a good guy or a bad guy.
We live in America. We don’t execute people in the streets. It’s not how it is supposed to be in this country. And we shouldn’t tolerate it when it happens in our name.
In 2009, when I was running my own indie game development business full-time, I thought I would invest in my own education and paid for the premium subscription content of a popular Internet business and marketing podcast.
I thought that I would get through the material quickly as I had the freedom to dedicate all of my time to it. Then I could cancel it after one month of payments. Maybe two.
I ended up sticking around for much longer, and I can’t say it wasn’t useful, but the entire time I felt frustrated by the format. I can’t quickly peruse audio and video, and that was what most of the content consisted of. And as for the content itself, I felt like I had to get through lots of “witty” banter between the hosts to get to the gold nuggets, if there were any.
But I can’t complain too much about the content. I was clearly not their target customer. It was meant for people who might have no experience with software or computers, so it might work for other people just fine.
There were forums populated with such apparently satisfied customers who wanted to learn what it takes to run a successful business, and some made some good success based on applying what they learned.
Except it seemed like almost each and every one of them was making their success by taking what they learned from the premium subscription and repackaging and selling it to others in their respective niches.
One person was doing OK with selling on eBay before she took up the lessons, and by the end of it, she was making a good living selling an info product on how to run a successful Internet business with basically all of the same lessons from this premium subscription. You know, but geared towards eBay.
And she was just one example. It seemed like no one wanted to apply the lessons to run their own existing business more effectively. Instead, they seemed to have stopped doing whatever they were struggling with before and started their new business as Internet marketing experts based on what they learned from a premium subscription information product about being an Internet marketing expert.
To be fair, in the land of the blind, the one-eyed man is king. To the right audience, these people WERE experts. They now knew something that most other people didn’t. I’m not a C++ expert when compared to the people who speak at CppCon, but I am expert enough when it comes to where I am employed, and especially when it comes to my family who are “not computer people” at all.
But the thing that bothered me about the other subscribers to the premium subscription was that their expertise wasn’t really theirs. They learned some tricks and techniques from somewhere else, but they didn’t apply it to their own businesses. So what do they really know?
At least I spend a significant amount of time actually using my expertise, so when someone asks me something about C++, I have some real authority and experience to back it up. They basically turned around and shoveled their new marketing know-how to the ignorant people who were willing to pay them for the information. “If you want to be successful, uh, here’s what these other guys told me.”
And boom. Now not only are they experts, but they’re commercially successful experts with a paying audience, which only grows their authority.
The personal development field sometimes has a bad reputation in this regard. Some people are great successes who might be trying to share some insight into how they became great successes.
But other so-called successful people really only seemed to have become a success when they started writing books and giving speeches telling other people how to be successful.
I subscribe to Sunday Dispatches by Paul Jarvis, and in this past Sunday’s newsletter he talked about the “advice gold rush”. Apparently seven years later the problem I described above has only gotten worse, and in many industries. Jarvis linked to a colorfully-titled article complaining about it called The Creative World’s Bullshit Industrial Complex:
Being industry famous should be the result of some contribution to the world that the industry respects and wishes to learn from. Or insights unique and useful that it genuinely makes people’s lives better.
Increasingly “creative coaches” and people with “keynote speaker” in their Twitter bios are making their quest to earn authority a higher priority than the very reason they got into this in the first place. Fueling the Complex is alluring catnip that feels like you’re advancing your career the same way answering a bunch of emails just feels productive.
I’m not innocent. I know I’ve done my share of contributing to the Complex on this blog, especially early on. I shared advice as if I had some experience actually applying that advice in my own work, and in reality I was just shoveling someone else’ manure.
But my most satisfying and gratifying work is when I wrote about my own hard-won experiences. When I write about my own failures no matter how huge or my own successes no matter how minor, they’re mine to share. I can say I know what I’m talking about and have some small chance that I’m right.
When I have those experiences, often that’s when I truly understand what someone else was saying all along. That’s when I can make the associations between someone’s advice and my reality.
In January, I said I had created a plan. This plan was to release a minimum viable product (MVP) and get it in the hands of at least one customer in at most 90 days.
My thinking behind this plan was that I should be able to put together a fairly complete game easily in that time, get it in front of paying customers, and get useful data about the market to help me decide what to do in the next three months. Maybe I would flesh out the game more, adding features and enhancements based on customer feedback. Maybe I would switch to a different project entirely if no one cared about this one. When I get real customer data from my 90 day project, I would interpret the data and make an informed decision then.
My project is now past its 180th day. Oof.
Pride, partly, and the lack of a relatively satisfying game experience. I didn’t want to release a broken, ugly piece of software, and when my original deadline was arriving, I decided I couldn’t release it in the state it was in.
MVPs are meant to be fairly complete products. They might be missing key features, such as copy and paste in a smart phone, or might have some clunkiness, but they are meant to be something you can hand to a customer so you can get feedback from them. You can ask for feedback about different aspects of the game, but real customer behavior requires real customers, not just people who claim they would pay for something when asked in a survey.
So what was wrong with what I was making? I wasn’t worried about a lack of animations or polish. I was worried about a lack of satisfying game play. Various features were in the game, but they weren’t working together very well.
My plan did not initially accommodate the need for time spent on balancing the game mechanics and economy, and while I knew I would always playtest and tweak, I didn’t realize how far off the mark the initial implementation would be. My game didn’t just feel out of balance. It felt broken. I couldn’t release it in that state.
I’ve been in this situation before. My first major commercial game Stop That Hero! was originally supposed to be a one month project that I woefully underestimated. I worked on it for well over a year before my indie game development business ran out of money. I kept slipping my self-imposed deadlines constantly, and I just kept working harder to try to bring the game to a finish line that kept getting further and further away.
There are other similarities between STH! and my current project. STH! was a Ludum Dare game originally that I decided to flesh out into a full commercial project after getting some good feedback, and my current project started out as a physics-based One Game a Month project with similarly good feedback. Both projects were being built using my own code instead of leveraging an existing engine (eventually Daniel Cook will hug me, and I will check it off of my indie game development bucket list). And in both cases, I worked on them mostly solo.
But there are some differences.
STH! was built when I was running my indie game development business full-time. I spent more time in one day working on that game than I do sometimes in one week for my current project now that I have a day job, am married, and have other responsibilities. Looking at my numbers, I think I could have built my current project in its current state within a few weeks of full-time effort, and I would probably have plenty of time to play other games as well.
But STH! was primarily about feature development, especially since I opted to start from scratch, and it was a long time before I got to the point where I could even play the game, let alone figure out if I need to change anything about it as a result of playtests.
For my current project, I developed a few simple prototypes early on. I created a quick text-based version of the game that took me moments to put together, and I spent a few days tweaking and changing it. I had a few systems that I was able to test out quickly and determine if the concept would work.
And I focused on getting something playable quickly ever since. For many months, I’ve been able to play the game, show it to people, and get feedback, although I haven’t had any serious playtesting sessions.
While STH! was delayed due to missing key functionality for a long time, this game is delayed due to what might be called “informed feature creep”. I say informed because I am not just adding features when I think of them but only after recognizing that they would make the basic game more complete.
But it does have the effect of changing what is considered “minimum” for my minimum viable product. Focusing on the need to ship helps me decide if a new idea is a must-have or not.
While my initial project plan was a good first effort, I clearly missed the target.
But it was more out of underestimating what had to be done than in underestimating what I knew had to be done. Everything I scheduled time for more or less got done when I said it would, but playing the game showed me gaps and problems that needed to be addressed with work I didn’t anticipate at the start.
And that’s to be expected. You should learn about your project as you work on your project, and there will always be changes to the plan as it hits reality. You should expects lots of changes and tweaks to the design of your game.
I knew game development requires playtests and balancing, but I forgot to address it in my project plan. Whoops.
And that oversight is why I’m in my seventh month of my three month project. That, and the fact that it takes me weeks to do what could probably take me mere days if I was 100% focused on the project.
Like many indie game developers, I have a day job.
It pays the bills, but in exchange it asks me to dedicate a significant portion of my time to it during a given week.
I am married. I like being married to my wife. Since love is spelled T-I-M-E, in order to continue being married to my wife, a portion of my time is also spent just being with my wife.
We have a house. Now, before you buy a house, everyone is excited that you’re looking. They ask about neighborhoods you are considering and let you know about realtor friends they have.
But once you buy a house, suddenly everyone’s tune changes to the sarcastic song of “Oh, have fun doing all the maintenance on it! That’s home-ownership for ya!”
Like, they knew. They knew the entire time, and yet they never said anything until you joined them in their misery! So a portion of my time is spent mowing the lawn, fixing things like dryer vent ducts and minor plumbing issues, and general cleaning.
I like to sleep a full night. Well, I don’t actually. I wish I could use that time for other things, but I know sleep has a bunch of benefits. So aside from the occasional all-nighter in an emergency, a portion of my time is spent being uselessly unconscious.
So between a day job, commuting, married life, home ownership maintenance, eating, and sleeping, I find it difficult enough to schedule enough time to make games on the side. Cut back on idle time spent on Twitter and Facebook, cut out TV watching, cut writing in my blog, and there’s still only so much time left in a day.
And there aren’t even any children in the picture yet.
So how do some of you find time to actually play games?
It amazes me to read that other part-time indie game developers not only have time to play a new release but to also finish it within a week and give their well-conceived thoughts on it.
I once read about an interview with a prominent game designer who was asked what his favorite video games were, and he admitted that he didn’t play games. I remember wondering at the time how it is possible that someone could be in the industry but not play the games made by that industry.
But if you’re busy, and you are trying to make time for what’s important, then the less important stuff gets cut.
When my choice is to make games or play games, even if the temptation is high for play, making gets priority. I can play later. Or I can make time to play, but it will be limited.
For instance, this past Saturday I played board games with a bunch of people. The evening was dedicated to it, and then it was over.
Other times, I have played Mario Kart or Smash Bros with friends, or I’ve found myself with some free time and decided to use it to play a single-player game.
But those times are rare. They’re definitely not daily, and I don’t find myself playing a game for many evenings in a row until I’ve finished it.
That’s because I’ve dedicated those evenings to making games. Or mowing, but assuming the grass is fine, then it’s dedicated to making games.
It’s not that I don’t want to play games. In fact, I do want to play the many games in my collection, including games I still have from the NES. I have this delusion that one day I’ll have time to sit down and properly finish Final Fantasy and all the Wizardry games. I was playing X-COM, but only when it was released on Humble Bundle, but I never did get around to playing Civilization: Beyond Earth. Heck, I bought Civilization 3 at a physical store many years ago, and it has yet to be installed on my computer. Despite my poor game-playing track record, I love playing games, and I would play them more if sleep wasn’t so important.
Playing games is also good for research. How do you make games if you don’t know what is already being done, or what the trends are, or what conventions to follow to avoid reinventing the wheel?
Playing games keeps me informed. When someone talking about game design refers to Super Mario Bros or StarCraft, I’m on the same page. When they say something about flagpole jumping or Kerrigan’s betrayal, I know exactly what they’re talking about.
But when they refer to StarCraft 2 or Fallout 3 or really almost any major game released in the past couple of years, I’m going to have trouble understanding references if they aren’t explained.
It’s kind of embarrassing. Growing up, I was the “kid who knew everything about Nintendo”, but today I would have no street cred.
But I find myself choosing between making games and playing games, and playing games isn’t chosen often in favor of making progress on my own creative projects.
So if you are one of those people who somehow makes time for both, please write a comment below to let me know: how do you do it? Do you find that some areas of your life are out of balance as a result, or do you somehow make it all work? Do you purposefully take a period of time off from your indie game development to play a new game to completion, or do you play games regularly and squeeze in game development in the time left over?