Commit Hook Implementation
Robert Widhopf-Fenk
Robert.Widhopf at robf.de
Thu Oct 5 00:15:24 BST 2006
On Tuesday, October 3, 2006 at 09:56:24, Erik Bågfors wrote:
> On 10/3/06, Robert Widhopf-Fenk <hack at robf.de> wrote:
> > Hi,
> >
> > has anyone already written a commit hook plugin, i.e. a
> > plugin doing some actions after a successful commit.
> >
> > Typical things that can be done there:
> > * send a notification email with the log
>
> Please take a look at the bzr-email plugin which does this..
I was so focused on hooks that I did not find it ...
http://bazaar-vcs.org/BzrHooks has now a note that
post-commit has already landed.
> > * create/update a RSS feed with the log
>
> Not that I know of. You can use the bzr-email plugin as a starting
> point.
It is even simpler now than I thought.
> > * sync an mirror
>
> For this, you have checkouts/bind. Basically, do this
> I have branch foo, and I want a public mirror of it
> cd foo
> bzr push sftp://host/~/public_html/foo
> bzr bind sftp://host/~/public_html/foo
>
> Now each commit you do goes to both the public "foo" and your
> private "foo"
After binding, commits must succeed on the master branch
before they are executed on the local one. I was more on
starting a background job which must not succeed.
Thanks,
Robert
More information about the bazaar
mailing list