# Tuesday, May 13, 2008
I recently was working with some shared code and didnt like the regulations or the publicity of SourceFourge, so I set up a home CVS server to distro the code. Like another individual I googled out and found a bunch of documentation from linux users, no offence but I dont have time to read 30 pages to edit a password file. so I duplicated notes from here -http://www.adp-gmbh.ch/blog/2004/november/3.html- in case its ever removed and added my own commentary and edited some things for the new version of cvsnt.

Wih the server I also just checked out TortoiseCVS (formally I used wincvs) I dont like how much its locked into explorer but its so easy that I dumped wincvs and only use the turtle.

Installation

The installation turns out to be quite straight forward. Starting the installer takes care of the entire installation.
The default installation installs two windows services: the cvsnt service (named CVSNT) and the cvsnt lock (named CVSNT Locking Service) service. Additionally, it also installs a default certificate.
The cvs.exe was installed into C:\Program Files\cvsnt. Install also adds to your path statment.

Creating a repository

A repository needs a root directory under which both the files under version control and auxiliary files for use by CVS server are stored. I created this directory manually:
C:> mkdir c:\CVSSERVER
However, this is not a CVS repository by itself; the CVS server needs to be told to use this directory as a repository. The CVS server (or service, respectively) is administered through a service control panel that can be invoked in the dos prompt like so: (or via start menu)
C:\> cvsnt.cpl 
Now, with cvsnt.cpl, one can go to the Repositories tab and add the created repository. I chose /test for the name of the repository.

A dialog informed me: C:/CVSSERVER, but is not a valid CVS repository.
Do you want to initialise it?

And yes, of course, that's what I wanted.
Then I pressed apply.
The initialization basically created a CVSROOT directory beneath c:\CVSSERVER and put some 55 files and yet another directory into CVSROOT.

Adding a user

After creating the repository, I needed to create a user that can access (that is store and retrieve files) the repository.
C:\>cvs -d:sspi:localhost:/test passwd -a some_user
Adding user some_user@localhost
New password: ******
Verify password: ******
cvs server: *WARNING* CVS user 'some_user' will not be able to log in until they are aliased to a valid system user.
The password that I have specified (and is hidden in the console) was password.
This command created \CVSSERVER\CVSROOT\passwd with the following content:
some_user:AuC4s3kI8ixcs
Now, some_user needs to be aliased (according to the warning returned by cvs) to a valid NT system user:
C:\>cvs -d:sspi:localhost:/test passwd -r SYSTEM\administrator some_user
Changing repository password for some_user@localhost
New password: ******
Verify password: ******
Although this seems a bit redundant, it looks like one has to give the password again. This is the password for the CVS user not the system account. The SYSTEM\administrator is the NT-FQ name of the local admin in this example.

Creating a module

Now, it was time to create a module which I named test_module:
C:\CVSSERVER\>mkdir test_module
C:\CVSSERVER\>cd test_module
For the beginning, I only stored one file, README.txt, into this module. (one file is required to start the module)
C:\CVSSERVER\test_module\>notepad README.txt
Here's the content of README.txt:
test_module
===========
This is some dummy text.
C:\CVSSERVER\test_module\>cvs -d:pserver:some_user:password@localhost:/test import TestModule no-vendor initial-release
I didn't specify the -m flag, so CVS opened the default editor likely notepad (as the environment variable CVSEDITOR is not set) to enter a message. 
CVS: ----------------------------------------------------------------------
CVS: Enter Log. Lines beginning with `CVS:' are removed automatically
CVS:
CVS: ----------------------------------------------------------------------

just say C for continue
.. and CVS answered with:
N tm/README.txt

No conflicts created by this import
The N obviously indicates that tm/README.txt is a new file.
Now, let's see what happened in C:\CVSSERVER>.
C:\CVSSERVER\test_module\>cd \..

C:\CVSSERVER>dir
Directory of C:\CVSSERVER
02.11.2004 23:35 <DIR> .
02.11.2004 23:35 <DIR> ..
02.11.2004 15:53 <DIR> CVSROOT
02.11.2004 23:35 <DIR> TestModule
Indeed, it added a new directory called TestModule What's in there?
C:\CVSSERVER\test_module\tm>dir
Directory of C:\test_repository\tm

02.11.2004 23:35 <DIR> .
02.11.2004 23:35 <DIR> ..
02.11.2004 23:35 <DIR> CVS
02.11.2004 23:35 506 README.txt,v
It contains a CVS directory (again, used for CVS use) and the README.txt (with a ,v suffix)
Now, the repository is ready to be used.


so in the end to connect
cvs -d:pserver:some_user:password@localhost:/test /TestModule

posted on Tuesday, May 13, 2008 11:06:21 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] Trackback
Related posts:
Election 2008
Slurp Slurp USB to gather good data
load dos zip game into dosbox
Thermite How-To
drop the netbios hell in XP
change VMware disk size

Referred by:
cvsnt (search.live.com) [Referral]
Comments are closed.