<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.slackwiki.com/index.php?action=history&amp;feed=atom&amp;title=Subversion</id>
	<title>Subversion - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.slackwiki.com/index.php?action=history&amp;feed=atom&amp;title=Subversion"/>
	<link rel="alternate" type="text/html" href="https://www.slackwiki.com/index.php?title=Subversion&amp;action=history"/>
	<updated>2026-04-08T14:23:48Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.40.0</generator>
	<entry>
		<id>https://www.slackwiki.com/index.php?title=Subversion&amp;diff=194&amp;oldid=prev</id>
		<title>Erik: Copy from old</title>
		<link rel="alternate" type="text/html" href="https://www.slackwiki.com/index.php?title=Subversion&amp;diff=194&amp;oldid=prev"/>
		<updated>2009-06-06T23:31:06Z</updated>

		<summary type="html">&lt;p&gt;Copy from old&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;[[Category:Tutorials]]&lt;br /&gt;
&lt;br /&gt;
== Slackware - SVN Howto ==&lt;br /&gt;
&lt;br /&gt;
--[[User:Dadexter|dadexter]] 02:49, 14 Dec 2005 (GMT)&lt;br /&gt;
&lt;br /&gt;
This how to will explain how to setup Subversion, a replacement for CVS.&lt;br /&gt;
These instructions were written for use with an apache2 web server. Don't know&lt;br /&gt;
if it will actually work with apache1. Thanks to my good old buddy cactus (e.cactuswax.net)&lt;br /&gt;
for the original version of this, which I adapted to Slackware :)&lt;br /&gt;
&lt;br /&gt;
1) Install Subversion&lt;br /&gt;
&lt;br /&gt;
Download subversion and compile it using these steps:&lt;br /&gt;
&lt;br /&gt;
# wget http://subversion.tigris.org/downloads/subversion-1.2.3.tar.bz2&lt;br /&gt;
# tar -jxvf subversion-1.2.3.tar.bz2&lt;br /&gt;
# cd subversion-1.2.3&lt;br /&gt;
# ./configure --prefix=/usr --with-apr=/usr/bin/apr-config --with-apr-util=/usr/bin/apu-config --with-zlib&lt;br /&gt;
# make&lt;br /&gt;
# checkinstall&lt;br /&gt;
&lt;br /&gt;
If you're on Slackware 10.2 and above, subversion should already be installed. If not, grab it&lt;br /&gt;
from your nearest friendly slackware mirror :)&lt;br /&gt;
&lt;br /&gt;
2) As root, create the svn root:&lt;br /&gt;
&lt;br /&gt;
# mkdir -p /home/svn/repositories&lt;br /&gt;
&lt;br /&gt;
3) Configure apache-svn support&lt;br /&gt;
&lt;br /&gt;
Add these 2 lines to your httpd.conf (mine is in /etc/apache2):&lt;br /&gt;
&lt;br /&gt;
  LoadModule dav_svn_module       lib/apache/mod_dav_svn.so&lt;br /&gt;
  LoadModule authz_svn_module     lib/apache/mod_authz_svn.so&lt;br /&gt;
&lt;br /&gt;
I use SSL for apache, so I need to add&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;Location /svn&amp;gt;&lt;br /&gt;
     DAV svn&lt;br /&gt;
     SVNParentPath /home/svn/repositories&lt;br /&gt;
     AuthzSVNAccessFile /home/svn/.svn-policy-file&lt;br /&gt;
     AuthName &amp;quot;Test SVN Repo&amp;quot;&lt;br /&gt;
     AuthType Basic&lt;br /&gt;
     AuthUserFile /home/svn/.svn-auth-file&lt;br /&gt;
     Satisfy Any&lt;br /&gt;
     Require valid-user&lt;br /&gt;
  &amp;lt;/Location&amp;gt;&lt;br /&gt;
&lt;br /&gt;
to my /etc/apache2/ssl.conf, inside the VirtualHost directive.&lt;br /&gt;
&lt;br /&gt;
Don't forget to restart your httpd at this point&lt;br /&gt;
&lt;br /&gt;
4) Setup the svn root directory:&lt;br /&gt;
&lt;br /&gt;
Create /home/svn/.svn-policy-file&lt;br /&gt;
&lt;br /&gt;
  [/]&lt;br /&gt;
  * = r&lt;br /&gt;
  &lt;br /&gt;
  [test:/]&lt;br /&gt;
  dadexter = rw&lt;br /&gt;
&lt;br /&gt;
The * in the / section is matched to anonymous users. Any access above and beyond read only will be prompted for a user/pass by apache AuthType Basic. The /svn/test section inherits permissions from those above, so anon users have read only permission to it. I granted myself read/write permissions to the repo.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Create the svn-auth-file&lt;br /&gt;
&lt;br /&gt;
This is either an htpasswd, or htdigest file. I used htpasswd. Again, because of SSL, I don't worry as much about password sniffing. htdigest would provide even more security vs sniffing, but at this point, I don't have a need for it.&lt;br /&gt;
&lt;br /&gt;
  htpasswd -cs /home/svn/.svn-auth-file dadexter&lt;br /&gt;
&lt;br /&gt;
The above creates the file (-c) and uses sha1 for storing the password (-s). The user cactus is created.&lt;br /&gt;
To add additional users, leave off the (-c) flag.&lt;br /&gt;
&lt;br /&gt;
  htpasswd -s /home/svn/.svn-auth-file userX&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Create a repository&lt;br /&gt;
&lt;br /&gt;
  svnadmin create --fs-type fsfs /home/svn/repositories/test&lt;br /&gt;
&lt;br /&gt;
I prefer the newer file-system based repository. No database corruption/blocking issues. (--fs-type fsfs)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Set permissions&lt;br /&gt;
&lt;br /&gt;
The apache user needs permissions over the new repository.&lt;br /&gt;
&lt;br /&gt;
  chown -R nobody.nobody /home/svn/repositories/test&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4) Client setup&lt;br /&gt;
&lt;br /&gt;
Install the package created above (or the package from the Slackware mirror) on your development machine.&lt;br /&gt;
Next, create a directory to hold your development stuff, and create the svn directory structure:&lt;br /&gt;
&lt;br /&gt;
  mkdir -p ~/coding&lt;br /&gt;
  cd ~/coding&lt;br /&gt;
  mkdir branches tags trunk&lt;br /&gt;
&lt;br /&gt;
Put your source files into the created trunk directory. Here, I copy my development directory for an online&lt;br /&gt;
reservation system I'm working on.&lt;br /&gt;
&lt;br /&gt;
  cp -R /home/martin/cal2/* trunk&lt;br /&gt;
&lt;br /&gt;
Finally, import your development project into the svn repository:&lt;br /&gt;
&lt;br /&gt;
  svn import -m &amp;quot;Initial import&amp;quot; https://192.168.100.1/svn/test/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5) Testing the checkout&lt;br /&gt;
&lt;br /&gt;
  cd ~&lt;br /&gt;
  rm -rf coding&lt;br /&gt;
  svn co https://192.168.100.1/svn/test/&lt;br /&gt;
&lt;br /&gt;
I end up with the same ~/coding I had before :)&lt;/div&gt;</summary>
		<author><name>Erik</name></author>
	</entry>
</feed>