Micro and Nano Mechanics Group
Revision as of 14:53, 18 January 2008 by Kwkang (Talk)

Let's assume that we want to create more than one Subversion (SVN) repository and SVN users may or may not access to each repository depending on their authorization. This webpage will explain how to configure Subversion and ViewVC settings under the circumstance of Apache HTTP server.


For simplicity, let's say we have two repositories REPO_A and REPO_B created under the SVN directory

/PATH/TO/SVN/REPO_A
/PATH/TO/SVN/REPO_B

Here /PATH/TO/SVN should be replaced appropriately according as where it is located in your system. Then we need to edit couple of things in the ViewVC configuration file, viewvc.conf

  1. Specify svn_roots, which says the path to each repository and assigns name, such as
    svn_roots = REPO_A: /PATH/TO/SVN/REPO_A,
                REPO_B: /PATH/TO/SVN/REPO_B
    
  2. Comment out root_parents. (Check this more)
  3. Activate root_as_url_component, which interpretes the first path component <ref>To know what is the first path component in the URL after the script location, refer ViewVC 1.1 URL Reference. You can download url-reference.html from http://viewvc.tigris.org/source/browse/viewvc/branches/1.0.x/docs/</ref> in the URL after the script location as the root to use.
    root_as_url_component = 1     
    

    By activating this option, the website URL becomes natural, e.g. http://micro.stanford.edu/ViewVC/REPO_A. Otherwise, it would be like http://micro.stanford.edu/ViewVC/?root=REPO_A.

Notes

<references/>