Subversion Add

Adding a file or directory to Subversion is quite easy. The following commands will add a file and a directory to the current Subversion working directory. The added file or directory is only added to the local working directory, and not to the Subversion repository. For that to happen, you’ll need to issue a Subversion commit to synch the files to the repository. The following commands simply add files and directories in the local working directory.

Add a file

svn add foo.c

Add a directory

svn add directory

Subversion Checkout

The Subverion Checkout command is used to pull out a working copy of a project from the main Subversion repository. The Checkout command signals the start of using version control. This command is usually performed once at the beginning, but sometimes, it can also be performed whenever there are major changes to a project structure. To perform a checkout, type the following command in the Terminal.

svn co http://repository/project/trunk .

The period at the end is very important.

It tells Subversion that you want a copy of “trunk” in the current directory.