Following on from using version control, prior to doing a release of some software, stabilize the application by “freezing” the codebase. This means developers are free to continue development on their own PCs but not allowed to check any files into the version control system
Checking in code right up to the moment a release is cut encourages quick hacks which often cause failure. So:
24 hours before release only changes for the release should be checked in.
2 hours before the release no changes should be checked in. Everyone should be testing.
Scale these times up or down depending on the scale of the project.