I understand that the "SVN checkout" command will do the initial get of file(s) from the Subversion repository and bring them locally to your working directory/copy and that the "SVN update" command will get changes to file(s) from the repository if changes have been made by others.
It seems to me though that an "update" is just a special case of a "checkout", that is, when a checkout occurs, it's getting all files since none yet exist locally and hence ALL of the files have "changed", and that behind the scenes these commands are doing largely the same thing. I assume the commands exist separately just as a means of simplification?
Or, are there other differences between the commands, for example, does "SVN update" get files get new files (files that exist in the repository that you don't have in your working copy) or just updates to existing files?
The SVN update Command. The svn update command lets you refresh your locally checked out repository with any changes in the repository HEAD on the server. It also tells you what has been changed, added, deleted. If a change has been made to a file you have also changed locally, svn will try to merge those changes.
svn export simply extracts all the files from a revision and does not allow revision control on it. It also does not litter each directory with . svn directories. svn checkout allows you to use version control in the directory made, e.g. your standard commands such as svn update and svn commit .
Commit = Commit/confirm your changes to the repository. Update = Get the latest version/changes from the repository. When you change a file and want to keep the changes, commit them to the repository. When you want to get the latest available version/s from the repository, use update to update your local files.
Advertisements. Subversion provides the checkout command to check out a working copy from a repository. Below command will create a new directory in the current working directory with the name project_repo.
As I see it, the big difference is that checkout
creates a working copy, whereas update
brings down changes to an existing working copy.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With