Svn
From LocalizationWiki
[edit]
Setting Up a svn server
1.Installing SVN
In Debian Linux -- using etch repository -- $apt-get install svn
2.Creating Repository
svnadmin create <path_to_repo>. svnadmin is a utility that comes with svn for creating repository. <path_to_repo> is the absolute path to where you want to creat the repo. ex : svnadmin create /svn
3.Making the svn repository accessible through network using svnserve
As root, edit /etc/inetd.conf to add the following (all on ONE line): svn stream tcp nowait svnowner /usr/bin/svnserve svnserve -i
As root, edit /etc/services to confirm or add the following: svn 3690/tcp # Subversion svn 3690/udp # Subversion
4.svn authentication.
Authentication settings are done in the two files passwd and svnserv.conf in the conf dir in your repository root The svnserv.conf file comes with a commented general template. Uncomment the following lines : [general] anon-access = read auth-access = write password-db = passwd realm = My First Repository
The username and password is created in the passwd file as follows: [users] test : testing Here, test is the username and testing is the password.
5.Putting a new project in the svn repository
Say we want to import a new project into the svn. We begin by creating a skeleton of the project to be imported. Make a temprorary directory and create the project skeleton:EX. mkdir tem_dir cd tem_dir mkdir ProjectA mkdir ProjectA/trunk mkdir ProjectA/branches mkdir ProjectA/tags You can create more than one project like that. After that, populate the project skeleton with the initial project file, if any. To import the project do(You must be in the tem_dir, (as in our example here) : svn import . <path_to_repos> -m 'Initial repository layout'
6.Checking out from the svn repo
To check out a project named, say, ProjectA : svn co <user>@<path_to_repo>/<proj_name> <proj_name> It could be something like : svn co tenzin@192.168.0.123:/svn/ProjectA ProjectA The project will then be checked out in your computer in the working directory with the name ProjectA
