POE::Session::Irssi

Emit POE events for Irssi signals
Download

POE::Session::Irssi Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Martijn van Beers
  • Publisher web site:
  • http://search.cpan.org/~martijn/

POE::Session::Irssi Tags


POE::Session::Irssi Description

Emit POE events for Irssi signals POE::Session::Irssi is a subclass of the POE::Session module helps you integrate POE and Irssi scripting. It connects the signals and commands handlers you define as POE events with the Irssi machinery. It also tries to clean up as much as possible when the script gets unloaded, by removing all the alarms your session has running.It does this cleaning up by installing an UNLOAD handler that will send an unload signal. See SIGNALS below for more information.SYNOPSIS use Irssi; use Glib; use POE qw(Loop::Glib); use POE::Session::Irssi; %IRSSI = ( ... fill in the usual stuff for scripts here ... ); POE::Session::Irssi->create ( irssi_commands => { hello => sub { my $args = $_; my ($data, $server, $witem) = @$args; $server->command("MSG $witem->{name} Hello $data!"); }, }, irssi_signals => { "message join" => sub { my $args = $_; my ($server, $channel, $nick, $address) = @$args; my $me = $server->{nick}; if ($nick eq $me) { $server->command("MSG $channel Hello World!"); } else { $server->command("MSG $channel Hi there, $nick"); } }, }, # Other create() args here.. ); Requirements: · Perl


POE::Session::Irssi Related Software