Bot::BasicBot::Pluggable::Module::RT - This is a plugin to access information about RT tickets on IRC
version 0.20
< you> RT#12345 < bot> RT 12345: there is a bug in the matrix! - open
This module uses RT::Client::REST::Ticket to connect to a RT server and grab information on tickets.
Bot::BasicBot::Pluggable::Module::RT - Retrieves information of RT tickets
See synopsis
The url of the RT server. Set it using:
!set RT server <url>
The login to use. Set it using:
!set RT login <login>
The password to use. Set it using:
!set RT password <password>
The output format the bot should use to display information. Set it using:
!set RT output <output_string>.
the string can contain the following placeholders :
%i : id of the ticket %q : queue of the ticket %c : creator of the ticket %s : subject of the ticket %S : status of the ticket %p : priotity of the ticket %C : time where it was created
Default is : 'RT %i: %s - %S';
The regexp that is used to extract the rt number from the body. Set it using:
!set RT regexp <some_regexp>.
Its first match should be the rt number. Default is (?:^|\s)rt\s*#?\s*(\d+)
#!/usr/bin/perl use strict; use warnings; use Bot::BasicBot::Pluggable; my $bot = Bot::BasicBot::Pluggable->new( server => "server", port => "6667", channels => ["#bottest"], nick => "arty", alt_nicks => ["arty_", "_arty"], username => "RT", name => "RT Bot", charset => "utf-8", # charset the bot assumes the channel is using ); my $rt_module=$bot->load("RT"); $rt_module->set(user_server => 'http://rt.yourcompany.com'); $rt_module->set(user_login => "user"); $rt_module->set(user_password => "password"); $bot->run();
Damien "dams" Krotkine, <dams@cpan.org>
<dams@cpan.org>
Please report any bugs or feature requests to bug-bot-basicbot-pluggable-module-rt@rt.cpan.org, or through the web interface at http://rt.cpan.org/. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-bot-basicbot-pluggable-module-rt@rt.cpan.org
Copyright 2007-2011 Damien "dams" Krotkine, All Rights Reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Damien "dams" Krotkine
This software is copyright (c) 2011 by Damien "dams" Krotkine.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Bot::BasicBot::Pluggable::Module::RT, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Bot::BasicBot::Pluggable::Module::RT
CPAN shell
perl -MCPAN -e shell install Bot::BasicBot::Pluggable::Module::RT
For more information on module installation, please visit the detailed CPAN module installation guide.