SVN::Notify::Config - Config-driven Subversion notification
This document describes version 0.0910 of SVN::Notify::Config, released March 5, 2008.
Set this as your Subversion repository's hooks/post-commit:
Alternatively, use a config file inside the repository:
This module is a YAML-based configuration wrapper on SVN::Notify. Any option of the base SVN::Notify or any of its subclasses can be rendered in YAML and will be used to perform the appropriate task. In essence, your hook script is your configuration file, so it can be a very compact way to use SVN::Notify.
Notes on a few of the options:
Each block is contructed as a YAML hash entry whose key is the path that triggers that block's action. This term is evaluated as a Perl regex and all path entries are relative to the repository root. You can use very sophisticated mapping between paths and handlers. For example, a new tag under any project goes to all developers, but regular commits to branch or trunk go to that project list only.
With the core SVN::Notify module, you were required to issue multiple to_regex_map entries. In SVN::Notify::Config, an implicit to_regex_map is constructed from the path hash and the array of to: elements of the YAML file.
Versions of SVN::Notify::Config prior to 0.09 contained a subtle error in logic which meant that multiple overlapping paths would not all fire, but rather only the last block defined would fire. This does not agree with core SVN::Notify behavior, where you could have multiple independent to_regex_map entries which would all fire.
For example, see the '/path' block in the SYNOPSIS, which should receive a ColorDiff e-mail for any commit under the other blocks. If you need to replicate the previous behavior, you can use negative lookahead's.
Autrijus Tang E<lt>email@example.comE<gt>
John Peacock E<lt>firstname.lastname@example.orgE<gt>
Copyright (c) 2006-2008 by John Peacock <email@example.com>. Portions copyright 2004-2006 by Autrijus Tang <firstname.lastname@example.org>.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
1 POD Error
The following errors were encountered while parsing the POD:
You forgot a '=back' before '=head1'
To install SVN::Notify::Config, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell
For more information on module installation, please visit the detailed CPAN module installation guide.