(Check-in before lunch and dinner) Do you work in small chunks & check in after completing each one?
7/05/2014 1:56 PM by
Frequently developers work on long or difficult features/bugs and leave code checked out for days or worse still, weeks.
- What happens if your laptop hard drive dies?
- What happens if you call in sick?
- How can you pair program if not sharing your changesets?
Figure: Eating one big meal every three days gives you a bellyache... (aka check in small portions regularly, one large check-in after a few days will give you a headache)
That's why source code should be checked in regularly. We recommend a check-in:
If the changes would break the build or are in a state that cannot be put into the main trunk, then this code should be put into a shelveset
(sometimes referred to as 'sandbox') in source control.
Another good reason to check-in regularly is that it makes it easier to merge your changes with other developers. If all developers check-in lots of changes in one go, you will spend a lot of your time resolving conflicts instead of doing work.
TIP: How can you enforce regular check-ins? Monitor them using a report to see who has not checked in
Do you feel this rule needs an update?