ubuntu svn post commit hook does not work, but works on manual running -
/usr/bin/svn update /var/project2_test/debug --username xxxx--password xxxx /bin/echo $rev >> /var/project2_test/svn.log
the log has been updated while committing. working copy never update. , run /home/admin/svn/project/hooks/post-commit hand. works!
- post-commit hook (any hook really)
- running in empty environment
- running under user credentials, on running hand (user of svn-server used)
- anyway, have debug hook's script under real conditions (as hook). in orderto it, have
- intercept output of
update
command (by redirecting stdout stderr) - show output user, perform commit, i.e, because stderr marshalled user in case of error in hook, have exit hook non-zero exit-code
- intercept output of
hook in debug-stage like
/usr/bin/svn update /var/project2_test/debug --username xxxx --password xxxx > &2 /bin/echo $rev >> /var/project2_test/svn.log exit 1
Comments
Post a Comment