Monday, February 11, 2013

"svn checkout" versus "svn update"

Some people are confused about the distinction between "svn checkout" and "svn update."

"svn checkout" creates a working copy based on data from the repository where no working copy previously existed.  You only need to run it once on any given computer.

"svn update" copies changes made by other people (like me) to the repository into your existing working copy.  Its main purpose for you in this class is to download changes that I make after you do the initial checkout, like new test scripts or marks from graded homework.

If you were working in a group, you'd use "svn update" to download changes to the project made by other group members.  You could do this even if you made changes that you hadn't committed.  Subversion is pretty good at merging changes made by multiple people in different parts of the same file, though occasionally you have to help it out.