Do that diff!

You’ve completed the feature or fixed the bug, written a few unit tests, polished the format and comments.  Now it’s time to commit the change…

Wrong!

You gotta diff that puppy! Any source code management system will let you review the differences between your branch and the existing code.

Never merge/check in without a diff.  It’s easy to overlook this simple step, but trust me, you may be surprised at the cruft — false steps, debug prints, etc. — that your are about put into “master”.

People who review your code will be looking at the diffs.  You owe it to them and yourself to take that step first.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s