mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-19 18:39:35 +01:00
50 lines
2.1 KiB
Plaintext
50 lines
2.1 KiB
Plaintext
More information coming soon. Work in progress.
|
|
--------------------------
|
|
See also: http://www.iso-9899.info/wiki/Candide
|
|
--------------------------
|
|
The first thing you'll want to do is edit pbot.pl and change the default
|
|
settings:
|
|
|
|
* If you did not extract/checkout PBot into ~/pbot (where ~/pbot/PBot
|
|
contains the PBot.pm module), you'll want to change $pbothome in pbot.pl
|
|
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
|
|
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
|
|
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
|
|
from disconnecting IRC when a module completes after forking:
|
|
|
|
/lib/perl5/site-perl/Net/IRC/Connection.pm around line 405 has a sub DESTROY:
|
|
|
|
404 # Standard destructor method for the GC routines. (HAHAHAH! DIE! DIE! DIE!)
|
|
405 sub DESTROY {
|
|
406 my $self = shift;
|
|
407 return; # <--- added to prevent disconnecting after forking exits
|
|
408 $self->handler("destroy", "nobody will ever use this");
|
|
409 $self->quit();
|
|
410 # anything else?
|
|
411 }
|
|
--------------------------
|
|
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
|
|
04:33:39 < candide> hi
|
|
04:33:50 < 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
|
|
04:35:11 < pragma_> like ~channel kick <args>
|
|
04:35:18 < pragma_> because kick has to be used in a channel
|
|
04:36:20 < pragma_> and you can still background the bot with ^Z
|
|
--------------------------
|
|
Coming soon to README:
|
|
|
|
* List of Perl module dependencies, for installation.
|
|
* Description of each PBot module, for customisation.
|
|
--------------------------
|
|
Todo:
|
|
|
|
* Add SSL and port options to pbot.pl.
|