The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

App::Wubot::Reactor::Icon - search for an appropriate icon for a message

VERSION

version 0.4.0

SYNOPSIS

      - name: icon
        plugin: Icon
        config:
          image_dir: /Users/your_id/.icons

DESCRIPTION

Attempts to find a suitable image for a message by looking for a file in the icon directory that matches a field on the message:

  - 'image' field

  - 'username' field

  - monitor key

  - monitor plugin name

  - monitor instance name

If no suitable icon can be found, then the image field will be set to 'wubot.png'.

Note that the Icon plugin no longer tries to parse any information in the username field. It is highly recommended that you use the User reactor plugin prior to using the Icon plugin so that the username field is parsed appropriately.

For more information, please see the 'notifications' document.

SUBROUTINES/METHODS

react( $message, $config )

The standard reactor plugin react() method.