Don't forget to change “newuser” and “newgroup” in the below shell script to the desired user & group for the created repository. The desired user is likely to be Apache's user (“nobody”, “www-data”, etc.), while the group can be whatever might be helpful in your environment.
The last line of this script just reminds me to also edit the Apache and ViewVC configuration files.
<source lang=“bash”>#!/bin/bash
if -z "$1" ; then
echo "You must pass the name of a new repository to this script." exit
fi
svnadmin create “$1”
chown -R newuser:newgroup “$1”
find “$1” -type d -exec chmod 770 {} \; find “$1” -type d -exec chmod g+s {} \;
find “$1” -type f -exec chmod 660 {} \;
echo “Done!” echo “Now don't forget to edit the files symlinked in /home/subversion/apache-conf/!”</source>