Click here to Skip to main content
15,886,199 members
Articles / All Topics
Technical Blog

How changing my commit messages made me more productive

Rate me:
Please Sign up or sign in to vote.
3.50/5 (9 votes)
5 May 2015CPOL1 min read 4K   4  
Confession. I sucked at writing commit messages. Messages like Fix, Style Things and Fix Again #yolo where common place. This did not really matter much as I was working by myself at the time, but I knew I had to start building a habit of writing better commit messages.

Confession. I sucked at writing commit messages. Messages like Fix, Style Things and Fix Again #yolo where common place. This did not really matter much as I was working by myself at the time, but I knew I had to start building a habit of writing better commit messages. But every time I started looking on the interwebs I found suggestions to write a heading, a proper body and some foot notes. I understand where this is useful, but working mainly on line of business applications and committing often made it seem like more of a chore than anything else.

Then someone at work shared this post about semantic commit messages.

"Now that's something I can get behind", I thought to myself. Short, sweet and easy to remember.

What really caught me off guard was that it made me a lot more productive.

Huh? You do it at the end how does it make you more productive?

Here's what happens. Writing the prefix forces you to commit only the work related to the one thing you should be doing. Either a Feature or a Fix or a Style Change etc. So I automatically start thinking about my commit message before I start working with the code. This means that when I start working with the code, I am focused on exactly what needs to be done and only that. Then I just do it. I get it done, commit and hop on over to whatever is next.

I also get a nice looking commit history that is easily readable and I leave bigger breadcrumbs for those that come after me.

This is also a great first step to eventually writing more detailed commit messages.

This article was originally posted at http://feeds.feedburner.com/sneakycode

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior)
Unknown
I write about Domain Driven Design, Clean Code and .net

Comments and Discussions

 
-- There are no messages in this forum --