NAME

SVN::Hooks::DenyFilenames - Deny some file names.

SYNOPSIS

This SVN::Hooks plugin is used to disallow the addition of some file names.

It's active in the pre-commit hook.

It's configured by the following directive.

DENY_FILENAMES(REGEXP, [REGEXP => MESSAGE], ...)

This directive denies the addition of new files matching the Regexps passed as arguments. If any file or directory added in the commit matches one of the specified Regexps the commit is aborted with an error message telling about every denied file.

The arguments may be compiled Regexps or two-element arrays consisting of a compiled Regexp and a specific error message. If a file matches one of the lone Regexps an error message like this is produced:

DENY_FILENAMES: filename not allowed: filename

If a file matches a Regexp associated with an error message, the specified error message is substituted for the 'filename not allowed' default.

Example:

DENY_FILENAMES(
    qr/\.(doc|xls|ppt)$/i, # ODF only, please
    [qr/\.(exe|zip|jar)/i => 'No binaries, please!'],
);

AUTHOR

Gustavo Chaves, <gnustavo@cpan.org>

BUGS

Please report any bugs or feature requests to bug-svn-hooks-denyfilenames at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=SVN-Hooks. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

You can find documentation for this module with the perldoc command.

perldoc SVN::Hooks

You can also look for information at:

COPYRIGHT & LICENSE

Copyright 2008-2009 CPqD, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.