Monday, March 12, 2012

Basic Commands for SVN

1. Creating a directory in Repo
For eg :: To create directory MobileApps, follow the following command.
svn mkdir http://xxx.xxx.xxx.xxx/svn/source/MobileApps -m "Adding Main Project Directory"

2. Importing project in SVN
svn import MyProject http://xxx.xxx.xxx.xx/svn/source/MobileApps -m "Adding Main Project Directory"
This command will import all the files within MyProject to MobileApps folder.

3. Deleting a directory in Repo
For eg :: To remove directory mobileapps-java, follow the following command.
svn delete http://xxx.xxx.xxx.xxx/svn/source/MobileApps/mobileapps-java -m "Deleting ..."

4. Creating a branch from trunk
svn copy http://xxx.xxx.xxx.xxx/svn/source/trunk/mobileapps-java/ http://xxx.xxx.xxx.xxx/svn/source/branches/mobileapps-java-mybranch/ -m "Creating branch for java apps"