Setting up local SVN server

From Notes_Wiki
Revision as of 04:51, 13 November 2012 by Saurabh (talk | contribs) (Created page with "=Setting up local SVN server= In case we want to maintain different revisions / version of a project on same system then we can setup local SVN. To create a SVN repository us...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Setting up local SVN server

In case we want to maintain different revisions / version of a project on same system then we can setup local SVN. To create a SVN repository use command:

svnadmin create <project_name>

in folder where we want to create repository. This would create a folder with name <project_name> and create SVN repository related files inside it. We never do anything to this directory except checking out project from this directory for working.

To checkout project from a SVN repository on same system we can use:

svn checkout file:///<full_path_to_project_folder>

Please note the use of triple slash (///) as double slash in above command will not work properly. When we checkout a working copy of project, we again get folder with name <project_name> created in work folder. We can work on this folder and use commands like 'svn commit' and 'svn update' to commit our local changes to server or to get latest version of project from server respectively.

SVN also has other useful commands like 'svn diff' which can be used to find difference between local copy and any previous revision of same file.