Click here to view code image
matthew@seymour:~$ svnadmin create /path/to/your_svn_repo_name
To add a new project to the repository, go to the top directory of the code that
is going to be placed into the repository. Then create three subdirectories:
branches, tags, and trunk. Move all of your files into trunk and enter
the following:
Click here to view code image
matthew@seymour:~$ svn import project
file:///your_svn_repo_name/your_project -m "First Import"
To check out code from an existing central repository, use this:
Click here to view code image
matthew@seymour:~$ svn checkout
file:///your_svn_repo_name/your_project/trunk your_project
To check in code after you have made changes, use the -m flag to add a note,
which is a good idea so that others know what the commit contains:
Click here to view code image
matthew@seymour:~$ svn commit -m "This fixes bug 204982."
To update the source code in your local repository from the main repository to
make sure you have all the latest changes to the code from other developers,
use this:
Click here to view code image
matthew@seymour:~$ svn update
To add new files to the repository, use the following:
Click here to view code image
matthew@seymour:~$ svn add file_or_dir_name
To delete files from the repository, use this:
Click here to view code image
matthew@seymour:~$ svn delete file_or_dir_name
Many open source projects that use Subversion host their code using
SourceForge, which also works with Git and Mercurial. Like the other code-
hosting sites discussed in this chapter, SourceForge is a great place to find
open source software projects that might be useful to you or to which you
might want to contribute through participation. You can find it at
http://sourceforge.net.