Setting Up Subversion in 5 minutes
There are several books about Subversion, some small some huge. Yet, none of them gives a 5 minute get-going guide. Most of the developers are seasoned CVS users, so we do not really need a tirade about version control - just get us going!
And (I can hardly stress this enough) we\'d really like Subversion to authenticate over SSH. Leave that "pasword db" (in essence - open text file) or Apache Module bullcrap, to somebody else. Neither do we need the WebDav for version control - thank you very much, but no.
The last time I set up a SVN repository (accidentally - my first time, too) it took me looking through 4 different books and a week\'s work on and off. Today I needed to do it, again and I found out that I did not remember much of the last experience. Well, it did not take me a week, but still more than I would want to spend on it. Anyway, to save myself time, in the future and in hopes of this being useful for folks who don\'t want to read 4 books, here is how it is done, on Unix (Windows can get lost, as far as I care):
1) Get the source or a binary from http://subversion.tigris.org
2) If you got a binary - you know what to do. If you have a source tar, either read the INSTALL doc that came with it or just do the usual \ "./configure", "make", "make install" \ that\'s what I did - I was too lazy to read and it worked, so - it may work for you, too.
3) Check that it installed by running: \ svn --version (client) \ and \ svnadmin --version (admin)
4) Create a repository by typing: \ svnadmin create /home/svn \ (the path of your repository will be /home/svn)
5) Let\'s import a module, now: \ go to the source tree of whatever you want imported and type: \ svn import -m "Importing my module" . file:///home/svn/mymodule
the dot after the comment is what you are importing (current folder, in this case) \ and the next parameter is the svn URL of where to import your module.
6) Go to /home/svn/conf/svnserve.conf, enable (remove comment) the General section and under it set: \ anon-access = none unless you want your repositories to be viewable (not editable) by anonymous users.
7) Grant read/write rights to the developer team: \ Put your developer accounts under some group with a command like: \ usermod -G devgroup steve
and then issue a self-explanatory series of commands: \ chgrp -R devgroup /home/svn \ chmod -R 770 /home/svn \ chmod g+s /home/svn/db (or g+t for BSD)
after that any unix user that is in the group devgroup, on the server, \ can checkout the code by: \ svn co svn+ssh://firstname.lastname@example.org/home/svn/mymodule
That\'s it. If this short guide is not clear enough for you, feel free to read 4 or 5 books about Sunversion. I\'d recommend to start with the Pragmatic Version Control with Subversion, from the Agile guys. It\'s the shortest and makes more sense than the other, larget books. Maybe you will need just one book, if you start with this one.
P.S. The free book on the Tigris site is a piece of crap. Don\'t waste your time. It\'s a classic case of "you get what you pay for". Sorry - just being honest.