SVN::Notify::HTML::ColorDiff - Subversion activity HTML notification with colorized diff


SVN-Notify documentation  | view source Contained in the SVN-Notify distribution.

Index


Name

Top

SVN::Notify::HTML::ColorDiff - Subversion activity HTML notification with colorized diff

Synopsis

Top

Use svnnotify in post-commit:

  svnnotify --repos-path "$1" --revision "$2" \
    --to developers@example.com --handler HTML::ColorDiff [options]

Use the class in a custom script:

  use SVN::Notify::HTML::ColorDiff;

  my $notifier = SVN::Notify::HTML::ColorDiff->new(%params);
  $notifier->prepare;
  $notifier->execute;

Description

Top

This subclass of SVN::Notify::HTML sends HTML formatted email messages for Subversion activity, and if the with_diff parameter is specified (but not attach_diff), then a pretty colorized version of the diff will be included, rather than the plain text diff output by SVN::Notify::HTML.

Usage

Top

To use SVN::Notify::HTML::ColorDiff, simply follow the instructions in SVN::Notify, but when using svnnotify, specify --handler HTML::ColorDiff.

Instance Interface

Top

Instance Methods

output_css

  $notifier->output_css($file_handle);

This method starts outputs the CSS for the HTML message. SVN::Notify::HTML::ColorDiff adds extra CSS to its output so that it can nicely style the diff.

output_diff

  $notifier->output_diff($out_file_handle, $diff_file_handle);

Reads the diff data from $diff_file_handle and prints it to $out_file_handle for inclusion in the notification message. The diff is output with nice colorized HTML markup. Each line of the diff file is escaped by HTML::Entities::encode_entities().

If there are any diff filters, this method will do no HTML formatting, but redispatch to SVN::Notify::output_diff. See Writing Output Filters for details on filters.

See Also

Top

SVN::Notify
SVN::Notify::HTML
CVSspam

To Do

Top

Top

Author

Top

David E. Wheeler <david@justatheory.com>

Copyright and License

Top


SVN-Notify documentation  | view source Contained in the SVN-Notify distribution.