Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Source Control best practice - periodically updating your working copy from the repository

(Note: This question is not specific to Subversion - I'm just using it here as an example.)

I know that the "svn update" command (or whatever the similar command is in other systems) will update your working copy with any changes to files from the repository. I also know that it's a best practice in source control to periodically do an svn update to make sure you've got the most recent set of changes before you ultimately commit (check in) those changes.

An alternative approach to this best practice (maybe it would be a worst practice :>) would be to manage potential conflicts only at commit (check-in) time, rather than periodically during the period that you're editing the file.

It seems like the best practice is taking a "pessimistic" approach of managing conflicts early and often, vs. an "optimistic" approach of managing conflicts only at commit time and managing all accumulated conflicts at that later time.

Am I stating the intent of the best practice vs. the alternative correctly?

like image 389
Emilio Avatar asked Feb 12 '10 20:02

Emilio


1 Answers

Personally I update my working copy every day when starting work. I find that conflicts are found early and resolved quickly that way.

like image 56
Eric J. Avatar answered Sep 28 '22 17:09

Eric J.