Re: Copying hooks automatically upon repository creation
From: Ryan Schmidt <subversion-2010d_at_ryandesign.com>
Date: Mon, 4 Oct 2010 13:42:34 -0500
On Oct 4, 2010, at 12:51, Tech Geek wrote:
> We use one repository per project. All repository lives in /var/lib/svn/.
As Andy said, you can write a script that creates the repository and then copies the scripts, then make sure you call that script instead of calling "svnadmin create" directly whenever you want a new repo. My version of this script creates the repository as the Apache user and symlinks in my common hooks and conf directories. I symlink instead of copying because I want all my repositories to always have the same hooks and conf files, and I want changes I make in them to be reflected in existing repositories. Here's my script:
#!/bin/bash
REPO="/path/to/subversion/repositories/$1"
if [ -e "$REPO" ]; then
sudo -u "$USER" svnadmin create "$REPO" || exit $?
|
This is an archived mail posted to the Subversion Users mailing list.
This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.