(~) QuickHowTo: Svn Server and Trac (without apache2) – Part 1

02Jun07

~# I was thinking for sometime now, to create a personal SVN server to use for my scripts and documents. More like a place holder that I would be able to have some kind of version control. So here is a short how to install and setup svn and trac (I just like its source browsing capabilities) without the need to install apache2 as well.

Subversion using svnserve.

Installing subversion & configuring repository.

1. Install subversion.

2. Create & initialize your svn repository:

  • mkdir $HOME/myrepo
  • svnadmin create $HOME/myrepo
  • Change the access rules for your repo:
    • vi $HOME/myrepo/conf/svnserve.conf & add/edit according to your needs:
      • realm = My Repository
      • anon-access = read
      • auth-access = write
      • password-db = passwd

3. Start svnserve:

  • sudo /usr/bin/svnserve -d -r $HOME/myrepo
  • if you don’t want to start svserve each time you boot, you may want to add a line like the above in “/etc/conf.d/local.start” (or rc.local if your are on Ubuntu).

Start using your repository

1. Import your your code:

  • mkdir ~/Scripts
  • touch ~/Scripts/script1.sh (or put your scripts in the directory).
  • svn import ~/Scripts -m “Initial Import” file:///$HOME/myrepo

2. List files in your repository:

3. Commit your changes:

  • cd into your working directory
    • cd ~/Scripts
    • commit any changes you have made
      • svn ci -m “first commit”

4. Add or delete new files to your repository:

  • Under your working directory:
    • svn add new_script.sh -m “New file Added”
    • svn delete old_script.sh -m “Old file deleted”

5. Check out your svn repository into a new directory:

  • create a new directory and cd into it
  • svn co file:///$HOME/myrepo
Advertisements


One Response to “(~) QuickHowTo: Svn Server and Trac (without apache2) – Part 1”

  1. 1 asd

    and what about trac???


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: