mirror of
https://github.com/pragma-/pbot.git
synced 2025-02-16 21:40:46 +01:00
No longer need to edit Net::IRC::Connection.pm
This commit is contained in:
parent
ed5181cf0d
commit
d31b7594a2
72
README
72
README
@ -4,6 +4,9 @@ See also: http://www.iso-9899.info/wiki/Candide
|
|||||||
--------------------------
|
--------------------------
|
||||||
PBot requires Perl 5.10, especially for !cc
|
PBot requires Perl 5.10, especially for !cc
|
||||||
--------------------------
|
--------------------------
|
||||||
|
PBot is intended for the Freenode IRC network. As such, it has not been
|
||||||
|
tested on other networks. Some IRC features, such as quieting, may need adjusting.
|
||||||
|
--------------------------
|
||||||
The first thing you'll want to do is edit pbot.pl and change the default
|
The first thing you'll want to do is edit pbot.pl and change the default
|
||||||
settings:
|
settings:
|
||||||
|
|
||||||
@ -14,57 +17,40 @@ to point to the directory that contains the PBot, config, data, etc directories.
|
|||||||
* Change the IRC settings in pbot.pl so that the bot-nick and identify password are
|
* Change the IRC settings in pbot.pl so that the bot-nick and identify password are
|
||||||
associated with a registered NickServ account, if you want channel auto-join to succeed.
|
associated with a registered NickServ account, if you want channel auto-join to succeed.
|
||||||
--------------------------
|
--------------------------
|
||||||
Then you'll need to get Net::IRC from CPAN. If you do not have root access, see
|
Then you'll need to get several modules from CPAN. If you do not have root access, see
|
||||||
http://perl.jonallen.info/writing/articles/install-perl-modules-without-root
|
http://perl.jonallen.info/writing/articles/install-perl-modules-without-root
|
||||||
|
|
||||||
After installing Net::IRC, you'll need to edit Net::IRC's Connection.pm module to prevent it
|
Net::IRC
|
||||||
from disconnecting IRC when a module completes after forking:
|
AppConfig::Std
|
||||||
|
Data::Dumper
|
||||||
/lib/perl5/site-perl/Net/IRC/Connection.pm around line 405 has a sub DESTROY; insert a return; statement
|
Getopt::Std
|
||||||
at line 407:
|
HTML::Entities
|
||||||
|
HTML::FormatText
|
||||||
404 # Standard destructor method for the GC routines. (HAHAHAH! DIE! DIE! DIE!)
|
HTML::Parse
|
||||||
405 sub DESTROY {
|
IPC::Open2
|
||||||
406 my $self = shift;
|
LWP::Simple
|
||||||
407 return; ## <--- added to prevent disconnecting after forking exits ##
|
LWP::UserAgent
|
||||||
408 $self->handler("destroy", "nobody will ever use this");
|
LWP::UserAgent::WithCache
|
||||||
409 $self->quit();
|
Net::Dict
|
||||||
410 # anything else?
|
SOAP::Lite
|
||||||
411 }
|
Text::Autoformat
|
||||||
--------------------------
|
Text::Balanced
|
||||||
In addition to Net::IRC, PBot and several pbot-modules also use the following built-in and CPAN modules:
|
URI::Escape
|
||||||
|
WWW::Wikipedia
|
||||||
use AppConfig::Std;
|
XML::RSS
|
||||||
use Data::Dumper;
|
|
||||||
use Getopt::Std;
|
|
||||||
use HTML::Entities;
|
|
||||||
use HTML::FormatText;
|
|
||||||
use HTML::Parse;
|
|
||||||
use IPC::Open2;
|
|
||||||
use LWP::Simple;
|
|
||||||
use LWP::UserAgent
|
|
||||||
use LWP::UserAgent::WithCache;
|
|
||||||
use Net::Dict;
|
|
||||||
use SOAP::Lite;
|
|
||||||
use Text::Autoformat;
|
|
||||||
use Text::Balanced;
|
|
||||||
use URI::Escape;
|
|
||||||
use WWW::Wikipedia;
|
|
||||||
use XML::RSS;
|
|
||||||
--------------------------
|
--------------------------
|
||||||
Some quick-and-dirty info on using stdin (pbot shell after running pbot.sh):
|
Some quick-and-dirty info on using stdin (pbot shell after running pbot.sh):
|
||||||
|
|
||||||
04:33:09 < pragma_> you can type in the bot's stdin to talk in channels as the bot
|
< pragma_> you can type in the bot's stdin to talk in channels as the bot
|
||||||
04:33:39 < candide> hi
|
< candide> hi
|
||||||
04:33:50 < pragma_> that was typing 'msg #pbot2 hi' from the bot's stdin
|
< pragma_> that was typing 'msg #pbot2 hi' from the bot's stdin
|
||||||
04:34:15 < pragma_> you can send bot commands to channel by using ~channel command
|
< pragma_> you can send bot commands to channel by using ~channel command
|
||||||
04:35:11 < pragma_> like ~channel kick <args>
|
< pragma_> like ~channel kick <args>
|
||||||
04:35:18 < pragma_> because kick has to be used in a channel
|
< pragma_> because kick has to be used in a channel
|
||||||
04:36:20 < pragma_> and you can still background the bot with ^Z
|
< pragma_> and you can still background the bot with ^Z
|
||||||
--------------------------
|
--------------------------
|
||||||
Coming soon to README:
|
Coming soon to README:
|
||||||
|
|
||||||
* List of Perl module dependencies, for installation.
|
|
||||||
* Description of each PBot module, for customisation.
|
* Description of each PBot module, for customisation.
|
||||||
--------------------------
|
--------------------------
|
||||||
Todo:
|
Todo:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user