This is the default stuff in post-commit.tmpl
, which I don't think do anything useful:
REPOS="$1"
REV="$2"
mailer.py commit "$REPOS" "$REV" /path/to/mailer.conf
How to make use of this hook to automate the deployment?
This is the default stuff in post-commit.tmpl
, which I don't think do anything useful:
REPOS="$1"
REV="$2"
mailer.py commit "$REPOS" "$REV" /path/to/mailer.conf
How to make use of this hook to automate the deployment?
The post-commit hook is called on the server-side in the repository, which is a database, so you won't be able to do much from such a hook.
So just do your deployment from your working copy, after your commit. The easiest is to make a script for this, and of course make it also under version control.
If you're on Windows, there's a nice tool shipped with TortoiseSVN called SuvWCRev that you can integrate from your script. It allows you to retrieve all your working copy information so that the thing you deploy have somewhere the trace of what revision it was made from, and other useful stuff.