You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Chris Van Brederode <cv...@intlogsys.com> on 2005/03/17 15:26:29 UTC

Hook Script question

We have set up SVN at work to do Configuration Managment of MS Word 
Documents.  Until the release with locking comes out, to minimize 
problems with trying to merge .doc files, we only have one person doing 
actual commits.  Other people email their changes.  To help with this, I 
have set up a check-out/export on a read only samba share, so people can 
grab files, edit, save to HD and email.

I'm trying to craft a hook-script (post-commit) that will update the 
check-out/export after each commit, to keep it up-to-date 
automatically.  I can't seem to get svn to run from inside the hook 
script.  We are using svn+ssh over net, and I have uid bit set on the 
hook script so it runs as root (who had the check out).  After I 
couldn't get update to run, I switched over to exports, and they don't 
run either.  Funny thing is, other commands in the script do run.

Is there something that prevents svn from running inside a hook script?

Here is my current script:

#! /bin/sh

REPOS="$1"
REV="$2"

/usr/bin/svn export file:///repo-url /samba/share --force > /root/update
echo $REV > /samba/share/revision.txt

This works perfectly when called from the prompt, but not otherwise.

Thanks,

Chris Van Brederode

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org