rbot
15 years agotranslator: fix NiftyTranslator
Raine Virta [Tue, 17 Feb 2009 16:12:27 +0000 (18:12 +0200)] 
translator: fix NiftyTranslator

15 years agotranslator: use *_with(:attribute => value) syntax to find elements
Raine Virta [Tue, 17 Feb 2009 14:18:38 +0000 (16:18 +0200)] 
translator: use *_with(:attribute => value) syntax to find elements

The way objects are currently searched inside Mechanize objects is
deprecated in WWW::Mechanize version 0.9.0, so we switch to the
preferred syntax.

15 years agotranslator: update GoogleTranslator for changes in their web interface
Raine Virta [Tue, 17 Feb 2009 01:59:24 +0000 (03:59 +0200)] 
translator: update GoogleTranslator for changes in their web interface

15 years agolast.fm plugin: list top tags and similar artists in artist info
Raine Virta [Mon, 16 Feb 2009 22:38:47 +0000 (00:38 +0200)] 
last.fm plugin: list top tags and similar artists in artist info

15 years agoircbot: fix nil error variable on ServerError
Giuseppe Bilotta [Tue, 17 Feb 2009 00:01:31 +0000 (01:01 +0100)] 
ircbot: fix nil error variable on ServerError

We were making use of an undefined variable e when catching ServerError
in the main loop.

15 years agofactoids: pass proper parameter from unreplied()
Giuseppe Bilotta [Mon, 16 Feb 2009 22:57:10 +0000 (23:57 +0100)] 
factoids: pass proper parameter from unreplied()

When passing on the Array of split words from unreplied() to facts()
make sure that the passed argument behaves like an Array/String from
the MessageMapper.

15 years agolastfm: put URL in artist summary
Giuseppe Bilotta [Mon, 16 Feb 2009 21:34:23 +0000 (22:34 +0100)] 
lastfm: put URL in artist summary

15 years agolastfm: say something when user top/weekly chart is empty
Giuseppe Bilotta [Mon, 16 Feb 2009 21:05:35 +0000 (22:05 +0100)] 
lastfm: say something when user top/weekly chart is empty

15 years agolastfm: limits to user data output
Giuseppe Bilotta [Mon, 16 Feb 2009 20:14:32 +0000 (21:14 +0100)] 
lastfm: limits to user data output

Define configuration keys for maximum and default number of user data
items output, with a separate value for shouts (which are usually much
more verbose and therefore would have a much lower maximum and default).

Each command also allow the specification of the number of entries
actually output (different than the default, clipped at the configured
maximum.

This way user data has the same rate limiting as events.

Internally, the switches for the user data are also made more uniform to
select, where it makes sense, different sentences depending on how many
entries are being displayed (none, all, some).

15 years agolast.fm plugin: rewrote the user-related info retrieval action to API 2.0
Raine Virta [Mon, 16 Feb 2009 17:49:35 +0000 (19:49 +0200)] 
last.fm plugin: rewrote the user-related info retrieval action to API 2.0

15 years agolast.fm plugin: removed year from event dates
Raine Virta [Sun, 15 Feb 2009 23:05:35 +0000 (01:05 +0200)] 
last.fm plugin: removed year from event dates

15 years agolast.fm plugin: list common artists in taste comparison
Raine Virta [Sun, 15 Feb 2009 00:35:39 +0000 (02:35 +0200)] 
last.fm plugin: list common artists in taste comparison

15 years agodictclient: put the Ruby/DICT URL in the LoadError message
Giuseppe Bilotta [Sun, 15 Feb 2009 21:43:44 +0000 (22:43 +0100)] 
dictclient: put the Ruby/DICT URL in the LoadError message

This should help people find the right package.

15 years agolastfm plugin: show something when no events are found
Giuseppe Bilotta [Sun, 15 Feb 2009 20:05:30 +0000 (21:05 +0100)] 
lastfm plugin: show something when no events are found

15 years ago+ @bot.path and datafile methods
Giuseppe Bilotta [Sun, 15 Feb 2009 00:30:51 +0000 (01:30 +0100)] 
+ @bot.path and datafile methods

We provide two methods that make it more simple and elegant for
botmodules to define paths relative to the bot's own directory
(botclass) and to the BotModule's (assumed) non-registry directory.

The first method is Irc::Bot#path(), which joins its arguments with the
botclass. This method can be used to access datafiles in the bot
directory with a much cleaner syntax; and since it uses File.join, the
resulting paths are also properly formatted on each platform, which
doesn't hurt.

Each BotModule now also carries a dirname() method that should return the
directory under botclass that holds the BotModule's datafiles. dirname()
defaults to the BotModule's name(), but it can be overridden, e.g. for
backwards compatibility (see the patch for the quotes plugin), or
for BotModules that share their datafiles.

Datafiles can be accessed using the BotModule#datafile() method that
joins the botclass, the dirname() and whatever other argument is passed.

15 years agoircbot: refactor and clean up botclass dir handling
Giuseppe Bilotta [Sat, 14 Feb 2009 22:56:49 +0000 (23:56 +0100)] 
ircbot: refactor and clean up botclass dir handling

Use File.join across the board, and refactor some botclass directory
handling. Most important changes:
 * failure to create the registry and safe_save directory is now fatal;
 * failure to create the local plugin directory prevents it from being
   added to the plugin path (with a warning);
 * botclass directory update from templates is now a standalone routine
   called during init, making it possible to use it in other cases too.

15 years agolastfm: move now playing maps to the bottom
Giuseppe Bilotta [Sat, 14 Feb 2009 22:07:40 +0000 (23:07 +0100)] 
lastfm: move now playing maps to the bottom

This ensures that 'lastfm who' triggers the correct map.

15 years agolast.fm plugin: removed redundant mappings
Raine Virta [Sat, 14 Feb 2009 21:53:45 +0000 (23:53 +0200)] 
last.fm plugin: removed redundant mappings

15 years agolast.fm plugin: enabled gettext on some replies, also small changes here and there...
Raine Virta [Sat, 14 Feb 2009 17:38:51 +0000 (19:38 +0200)] 
last.fm plugin: enabled gettext on some replies, also small changes here and there to make replies consistent with rbot's usual style

15 years agolast.fm plugin: first argument of taste comparison now optional
Raine Virta [Thu, 12 Feb 2009 23:54:16 +0000 (01:54 +0200)] 
last.fm plugin: first argument of taste comparison now optional

15 years agolast.fm plugin: simplified last.fm username resolution so that possible user aliases...
Raine Virta [Thu, 12 Feb 2009 22:50:59 +0000 (00:50 +0200)] 
last.fm plugin: simplified last.fm username resolution so that possible user aliases in @registry are favored over literal last.fm users

15 years agolast.fm plugin: fixed taste comparison xml parsing failing in case of nonexistent...
Raine Virta [Thu, 12 Feb 2009 22:22:52 +0000 (00:22 +0200)] 
last.fm plugin: fixed taste comparison xml parsing failing in case of nonexistent user(s)

15 years agomarkov: localize strings
Giuseppe Bilotta [Thu, 12 Feb 2009 21:35:09 +0000 (22:35 +0100)] 
markov: localize strings

15 years agomarkov: show queue size only when not empty
Giuseppe Bilotta [Thu, 12 Feb 2009 21:32:24 +0000 (22:32 +0100)] 
markov: show queue size only when not empty

15 years agomarkov plugin: add the size of the learning queue to the status message.
Spencer Rinehart [Thu, 12 Feb 2009 20:14:44 +0000 (15:14 -0500)] 
markov plugin: add the size of the learning queue to the status message.

15 years agolastfm: change verb usage and settings
Giuseppe Bilotta [Thu, 12 Feb 2009 18:37:49 +0000 (19:37 +0100)] 
lastfm: change verb usage and settings

15 years agoircbot: sendmsg filtering
Giuseppe Bilotta [Wed, 11 Feb 2009 22:34:16 +0000 (23:34 +0100)] 
ircbot: sendmsg filtering

We allow a filter to manipulate the arguments of sendmsg() by running
them through the filters of the :sendmsg group. The DataStream passed to
the filters has four keys:
  :text => the message text
  :type => the message type (typically, PRIVSMG or NOTICE)
  :dest => the destination (typically, a Channel or User)
  :options => options passed to sendmsg, merged with the default ones

15 years agoutils: htmlinfo filtering doc cleanups
Giuseppe Bilotta [Wed, 11 Feb 2009 20:00:22 +0000 (21:00 +0100)] 
utils: htmlinfo filtering doc cleanups

Fix a typo in a comment and specify 'htmlinfo' in the debug message.

15 years agogeoip: make the GeoIP module a standalone
Giuseppe Bilotta [Tue, 10 Feb 2009 00:19:03 +0000 (01:19 +0100)] 
geoip: make the GeoIP module a standalone

The geoip plugin defines and makes use of a GeoIP module to handle the
actual geoip data retrieval. The module used to be defined in the same
namespace as the plugin, and therefore in a barely accessible anonymous
module.

Move the GeoIP module to the outermost namespace to allow it to be
accessible from scripts and plugins too.

15 years agogeoip: also read lat/lon coordinates
Giuseppe Bilotta [Tue, 10 Feb 2009 00:08:00 +0000 (01:08 +0100)] 
geoip: also read lat/lon coordinates

GeoIP tool also offer latitude and longitude, so read them as well.

15 years agobans: put badwords in message() too
Giuseppe Bilotta [Mon, 9 Feb 2009 23:31:57 +0000 (00:31 +0100)] 
bans: put badwords in message() too

Move the whitelist and badwords check in the message() method instead of
triggering on listen(). This is more correct and more efficient, and it
ensures that the whitelist protects mass-highlighters too.

15 years ago+ (bans) added masshl ban option
Simon Hafner [Sun, 1 Feb 2009 19:08:25 +0000 (20:08 +0100)] 
+ (bans) added masshl ban option

When a masshl ban is added, the bot will ban (or kick or whatever)
anybody that calls more than a given fixed number of users or a
percentage of in-channel users.

15 years agogrouphug: htmlinfo filter
Giuseppe Bilotta [Sun, 8 Feb 2009 14:05:59 +0000 (15:05 +0100)] 
grouphug: htmlinfo filter

15 years agogrouphug: refactor confession retrieval
Giuseppe Bilotta [Sun, 8 Feb 2009 13:54:31 +0000 (14:54 +0100)] 
grouphug: refactor confession retrieval

Turn the confession extraction into its own method, and use it both for
specific and random confession retrieval.

15 years agogrouphug: fix retrieval of spurious confessions
Giuseppe Bilotta [Sun, 8 Feb 2009 13:34:52 +0000 (14:34 +0100)] 
grouphug: fix retrieval of spurious confessions

The real confessions are in the 'main' div, so rather than
second-guessing their true location (and getting it wrong every time the
site changes layout), just skip to the 'main' div before looking for
content.

15 years agogrouphug: log errors
Giuseppe Bilotta [Sun, 8 Feb 2009 13:04:36 +0000 (14:04 +0100)] 
grouphug: log errors

15 years agobash plugin: split long quotes at markers
Giuseppe Bilotta [Sat, 7 Feb 2009 18:46:58 +0000 (19:46 +0100)] 
bash plugin: split long quotes at markers

15 years agoremind plugin: added possibility to reference times that are the next day as hh:mm
Raine Virta [Wed, 4 Feb 2009 21:36:22 +0000 (23:36 +0200)] 
remind plugin: added possibility to reference times that are the next day as hh:mm

15 years agolastfm plugin: a small change in the last.fm api had broken the artist command
Raine Virta [Tue, 3 Feb 2009 12:44:05 +0000 (14:44 +0200)] 
lastfm plugin: a small change in the last.fm api had broken the artist command

15 years agohangman plugin: rudimentary stats tracking along with some other enhancements
Raine Virta [Tue, 3 Feb 2009 12:42:01 +0000 (14:42 +0200)] 
hangman plugin: rudimentary stats tracking along with some other enhancements

15 years agoslashdot plugin: fix filter for multiple articles
Giuseppe Bilotta [Fri, 6 Feb 2009 23:47:58 +0000 (00:47 +0100)] 
slashdot plugin: fix filter for multiple articles

15 years agorss plugin: don't abort if errors were found but rss is defined
Giuseppe Bilotta [Fri, 6 Feb 2009 18:29:32 +0000 (19:29 +0100)] 
rss plugin: don't abort if errors were found but rss is defined

If we always abort, a failing first parser will cause a failure even though a
subsequently tried parser succeeded in getting the feed right. So only
return nil if rss was nil when the error list wasn't empty.

15 years agoircbot: suppress warning
Giuseppe Bilotta [Sun, 1 Feb 2009 16:44:01 +0000 (17:44 +0100)] 
ircbot: suppress warning

parenthesize argument(s) for future version

15 years ago+ (plugins/rss) rss.announce_timeout config variable
dmitry kim [Sat, 31 Jan 2009 22:06:21 +0000 (01:06 +0300)] 
+ (plugins/rss) rss.announce_timeout config variable

15 years agorss plugin: fix return/error handling in parseRss
Giuseppe Bilotta [Sat, 31 Jan 2009 10:49:18 +0000 (11:49 +0100)] 
rss plugin: fix return/error handling in parseRss

Commit 36f1f28e668919dfab75c8fc4d1020abad351bd1 borked error handling as
it assumed that a false or nil rss implied a nonempty errors, and it
failed to return early.

Fix by removing the early check for a missing rss and wrapping the
report_problem (and the previously missing 'return nil') in the check
for a nonempty errors array.

15 years agolaunch_here: be more compatible with git < 1.5.x
Giuseppe Bilotta [Fri, 30 Jan 2009 22:41:14 +0000 (23:41 +0100)] 
launch_here: be more compatible with git < 1.5.x

People living in the stone age (e.g. those stuck using Debian stable)
still have git 1.4.4.4, which doesn't support git log --pretty=format.
So we parse the git log --pretty=raw format instead, which should be
available even on such older systems.

For the same reason, parse git diff-index --stat instead of git diff
--shortstat.

15 years ago* (registry) rdoc fix
Giuseppe Bilotta [Fri, 30 Jan 2009 18:28:59 +0000 (19:28 +0100)] 
* (registry) rdoc fix

A stupid missing hash sign prevented the full registry accessor doc from
being parsed by rdoc.

15 years agorss plugin: try all RSS parsers
Giuseppe Bilotta [Fri, 30 Jan 2009 17:24:34 +0000 (18:24 +0100)] 
rss plugin: try all RSS parsers

Some feeds fail when parsed by some parsers, but work correctly with
others (e.g. http://www.blueman.com/community/rss fails with xmlparser
but not with REXML). So try all of them and only abort if none works
rather than failing because the default parser fails.

15 years agoquotes plugin: add missing 'lastquote :channel' map
Giuseppe Bilotta [Fri, 30 Jan 2009 14:40:27 +0000 (15:40 +0100)] 
quotes plugin: add missing 'lastquote :channel' map

15 years agoquotes plugin: 'other channel' commands must be mapped earlier
Giuseppe Bilotta [Fri, 30 Jan 2009 14:35:03 +0000 (15:35 +0100)] 
quotes plugin: 'other channel' commands must be mapped earlier

Due to the way mapping work, quote commands whose first parameter is a
channel must be mapped before the ones that implicitly refer to the
current channel.

This has the upside that they really work, and the downside that
commands that refer to the current channel must specify the channel if
their argument begins wit something that looks like a channel spec.
However, this last case is extremely rare, so we're fine.

15 years agoIRC Framework: fix wrong rfc casemaps
Giuseppe Bilotta [Thu, 29 Jan 2009 20:56:33 +0000 (21:56 +0100)] 
IRC Framework: fix wrong rfc casemaps

The RFC1459 casemaps had the non-letter casemapping the wrong way
around. Fix by swapping them.

15 years agomarkov plugin: stricter permission on ignore and probability
Giuseppe Bilotta [Wed, 28 Jan 2009 21:53:33 +0000 (22:53 +0100)] 
markov plugin: stricter permission on ignore and probability

15 years agoircbot: optimize ignore loops
Giuseppe Bilotta [Wed, 28 Jan 2009 20:39:18 +0000 (21:39 +0100)] 
ircbot: optimize ignore loops

Break early from ignore checks, and skip them altogether when the
message is ignored already.

15 years agoircbot: irc.ignore_channels config option
Giuseppe Bilotta [Wed, 28 Jan 2009 20:36:38 +0000 (21:36 +0100)] 
ircbot: irc.ignore_channels config option

In some circumstances the user might want to turn the bot into a pure
logbot for some channels. This can now be achieved by adding that
channel to the irc.ignore_channels config key, that makes the bot ignore
all PRIVMSG to that channel (note that notices and service messages such
as joins and parts are still acted on, just like for irc.ignore_users).

15 years agoimdb plugin: fixed the ratings regex
Matthias Hecker [Wed, 28 Jan 2009 19:47:00 +0000 (20:47 +0100)] 
imdb plugin: fixed the ratings regex

15 years agorss plugin: don't warn on rewatch
Giuseppe Bilotta [Wed, 28 Jan 2009 17:11:18 +0000 (18:11 +0100)] 
rss plugin: don't warn on rewatch

There is no need to warn when calling watchRss on a watched feed; in
fact, since watchRss() is called every time a watcher is added, it just
spam the channels with a useless message that also provides unnecessary
information. So just return.

15 years agorss plugin: compact list of rss feeds
Giuseppe Bilotta [Wed, 28 Jan 2009 17:01:55 +0000 (18:01 +0100)] 
rss plugin: compact list of rss feeds

When lots of rss feeds are defined, the bot will flood the channel on
rss list. Fix by showing a compact list when the number of feeds is
higher than the maximum output lines.

15 years agoircbot: the reconnect must be protected
Giuseppe Bilotta [Wed, 28 Jan 2009 13:51:21 +0000 (14:51 +0100)] 
ircbot: the reconnect must be protected

The reconnect() call in the main loop must be protected in the
begin/rescue blocks. Most of the rescue blocks can be fall-through,
because the begin/end is wrapped in a loop. The only exception is the
ServerError block that issues a retry lest too_fast is reset to false
even when it should be true.

15 years agodict plugin: ircify html in demauro search result
Giuseppe Bilotta [Tue, 27 Jan 2009 23:17:35 +0000 (00:17 +0100)] 
dict plugin: ircify html in demauro search result

Demauro's search results can contain some HTML, so clean it up before
output.

15 years agoquotes plugin: remove a done TODO item
Giuseppe Bilotta [Tue, 27 Jan 2009 22:07:22 +0000 (23:07 +0100)] 
quotes plugin: remove a done TODO item

15 years ago* (rss.rb) bypass the http cache on !rss rewatch
dmitry kim [Tue, 27 Jan 2009 13:27:10 +0000 (16:27 +0300)] 
* (rss.rb) bypass the http cache on !rss rewatch

15 years ago* (httputils) get_response must refresh the cached object even if :cache => false
dmitry kim [Tue, 27 Jan 2009 15:11:31 +0000 (18:11 +0300)] 
* (httputils) get_response must refresh the cached object even if :cache => false

15 years agoazgame plugin: use Wordlist provider
Giuseppe Bilotta [Tue, 27 Jan 2009 21:16:56 +0000 (22:16 +0100)] 
azgame plugin: use Wordlist provider

15 years agowordlist: strip UTF-8 BOM on load
Giuseppe Bilotta [Tue, 27 Jan 2009 20:58:30 +0000 (21:58 +0100)] 
wordlist: strip UTF-8 BOM on load

Some editors put a BOM at the beginning of UTF-8 files, and it's not
stripped by Ruby's String#strip, so we have to get rid of it ourselves.

15 years agowordlist: exist? method
Giuseppe Bilotta [Tue, 27 Jan 2009 20:54:59 +0000 (21:54 +0100)] 
wordlist: exist? method

The new Wordlist.exist? method can be used to check if a wordlist file exists.
It will refuse to check upstream of the wordlist base directory

15 years agowordlist: Wordlist.list command and UI
Giuseppe Bilotta [Tue, 27 Jan 2009 20:46:11 +0000 (21:46 +0100)] 
wordlist: Wordlist.list command and UI

Introduce an elementary Wordlist.list() command that accepts an optional
:pattern option to restrict the list to wordlists matching the given
pattern.

Also introduce a wordlist UI to list wordlists from IRC.

15 years agohangman plugin: tell who nailed the word/killed the guy
Giuseppe Bilotta [Tue, 27 Jan 2009 13:15:07 +0000 (14:15 +0100)] 
hangman plugin: tell who nailed the word/killed the guy

15 years agohangman plugin: various improvements including support for wordlists
Raine Virta [Tue, 27 Jan 2009 01:30:25 +0000 (03:30 +0200)] 
hangman plugin: various improvements including support for wordlists

15 years agowordlist provider
Raine Virta [Mon, 26 Jan 2009 03:06:00 +0000 (05:06 +0200)] 
wordlist provider

15 years agourl plugin: urls info should work regardless of config
Giuseppe Bilotta [Tue, 27 Jan 2009 01:14:33 +0000 (02:14 +0100)] 
url plugin: urls info should work regardless of config

The 'urls info' command to manually query for link information should
always work, regardless of the setting of the url.only_on_channels
config setting.

Fix by making the channels list for handle_urls() into an option
(defaulting to url.only_on_channels) and passing an empty list from
info().

15 years agourl plugin: option hash for handle_urls()
Giuseppe Bilotta [Tue, 27 Jan 2009 01:08:56 +0000 (02:08 +0100)] 
url plugin: option hash for handle_urls()

Turn handle_urls() options (other than the message) into a parameter
hash.

15 years agorss plugin: fix watcher for empty feed
Giuseppe Bilotta [Mon, 26 Jan 2009 00:05:59 +0000 (01:05 +0100)] 
rss plugin: fix watcher for empty feed

15 years agorss plugin: parseRss returns the number of found items
Giuseppe Bilotta [Sun, 25 Jan 2009 23:47:04 +0000 (00:47 +0100)] 
rss plugin: parseRss returns the number of found items

Change the parseRss routine to return the number of found items, or nil
in case of error. This helps clearly differentiate between empty feeds
(which are still legit) and b0rked feeds.

This change in logic does not alter the fact that a feed update with no
items will not wipe existing old feed items.

15 years ago+ (rss.rb) monkey-patch some basic common api over different rss item impls
dmitry kim [Sat, 24 Jan 2009 00:36:37 +0000 (03:36 +0300)] 
+ (rss.rb) monkey-patch some basic common api over different rss item impls

15 years agolaunch_here: rewrite git revision retrieval
Giuseppe Bilotta [Fri, 23 Jan 2009 01:34:23 +0000 (02:34 +0100)] 
launch_here: rewrite git revision retrieval

Use low-level ('plumbing') git commands to retrieve the current
commit/revision/work tree status when we're being launched from a git
tree. This is faster (less shell escapes) and should work equally well
with all git versions (past, present and future).

15 years agolaunch_here: add commit subject rather than svn id to revision
Giuseppe Bilotta [Thu, 22 Jan 2009 22:29:50 +0000 (23:29 +0100)] 
launch_here: add commit subject rather than svn id to revision

There are no git-svn-ids in our repository, so don't look for them.
Instead, put the last commit subject next to the revision to ease
identification of the commit.

15 years agohangman plugin
Raine Virta [Thu, 22 Jan 2009 21:36:28 +0000 (23:36 +0200)] 
hangman plugin

15 years agoUpdate AUTHORS
Giuseppe Bilotta [Thu, 22 Jan 2009 15:49:02 +0000 (16:49 +0100)] 
Update AUTHORS

15 years agoUpdate po files
Giuseppe Bilotta [Thu, 22 Jan 2009 15:34:03 +0000 (16:34 +0100)] 
Update po files

15 years agorss plugin: mangle email in git format
Giuseppe Bilotta [Thu, 22 Jan 2009 14:28:45 +0000 (15:28 +0100)] 
rss plugin: mangle email in git format

Also fix a comment typo on the flyby

15 years agodice, 8ball: always add the nick to the reply
Giuseppe Bilotta [Thu, 22 Jan 2009 02:09:07 +0000 (03:09 +0100)] 
dice, 8ball: always add the nick to the reply

15 years ago+ (userdata) method delete_botdata(key)
Simon Hafner [Wed, 21 Jan 2009 20:58:02 +0000 (21:58 +0100)] 
+ (userdata) method delete_botdata(key)

15 years ago+ (reply) config option to force reply to query
Simon Hafner [Wed, 21 Jan 2009 15:49:31 +0000 (16:49 +0100)] 
+ (reply) config option to force reply to query

+ (reply) symbol to bypass the config option
* (plugins) fixed url according to the patch

The symbols are:
:to => :public   force the message to be replied in channel (if any)
:to => :private  force the message to be replied in private
:to => :auto     takes core.private_replies (default)

15 years ago* (plugins) changed to the new reply schema (:nick)
Simon Hafner [Wed, 21 Jan 2009 15:02:08 +0000 (16:02 +0100)] 
* (plugins) changed to the new reply schema (:nick)

15 years ago+ (reply) add new option to control nick prefixing
Simon Hafner [Wed, 21 Jan 2009 14:53:01 +0000 (15:53 +0100)] 
+ (reply) add new option to control nick prefixing

Message#reply() now accepts a :reply option
:nick => false   don't prefix nick
:nick => true    prefix nick
:nick => :auto   take core.reply_with_nick (default)

15 years agobash plugin: bash latest is not broken
Giuseppe Bilotta [Tue, 20 Jan 2009 22:38:31 +0000 (23:38 +0100)] 
bash plugin: bash latest is not broken

15 years agobash plugin: document bash search
Giuseppe Bilotta [Tue, 20 Jan 2009 22:35:06 +0000 (23:35 +0100)] 
bash plugin: document bash search

15 years agobash plugin: refactor and localize help
Giuseppe Bilotta [Tue, 20 Jan 2009 22:33:13 +0000 (23:33 +0100)] 
bash plugin: refactor and localize help

15 years agoircbot: fix reconnect() waiting
Giuseppe Bilotta [Thu, 15 Jan 2009 19:30:06 +0000 (20:30 +0100)] 
ircbot: fix reconnect() waiting

The refactored reconnect() method would only wait when the socket was
connected at the time it got called. In case where the socket would have
closed earlier (e.g. because of a network I/O error) it would reconnect
directly, which would for example fail to prevent fast reconnections.

Fix by fencing the wait code with a check for @last_rec (checked before the
optional disconnect) rather than keeping it with the socket connect check,
and always initializing @last_rec on socket connect.

A side effect of this strategy is that reconnect() will only wait if the bot
was previously connect, or if it got disconnected by anything but the
disconnect() method. Callers of disconnect() should take care of waiting
themselves if they plan to reconnect.

15 years agoircbot: SIGUSR1 forces a reconnect
Giuseppe Bilotta [Thu, 15 Jan 2009 03:46:50 +0000 (04:46 +0100)] 
ircbot: SIGUSR1 forces a reconnect

15 years agoircbot: refactor reconnection into its own method
Giuseppe Bilotta [Thu, 15 Jan 2009 03:32:56 +0000 (04:32 +0100)] 
ircbot: refactor reconnection into its own method

15 years agoauth: better clarify the allow/deny syntax
Giuseppe Bilotta [Thu, 15 Jan 2009 03:31:46 +0000 (04:31 +0100)] 
auth: better clarify the allow/deny syntax

15 years agoauth core botmodule: fix permission view without a specified user
Giuseppe Bilotta [Thu, 8 Jan 2009 20:49:10 +0000 (21:49 +0100)] 
auth core botmodule: fix permission view without a specified user

15 years agofortune: configurable options for the command
Giuseppe Bilotta [Thu, 8 Jan 2009 16:04:02 +0000 (17:04 +0100)] 
fortune: configurable options for the command

15 years agofortune plugin: fix autodetection
Giuseppe Bilotta [Thu, 8 Jan 2009 15:36:26 +0000 (16:36 +0100)] 
fortune plugin: fix autodetection

An empty String is not false in Ruby, so check for it properly. Also,
find_fortune needs a message passed to it, to be used when it discovers
the correct path.

15 years agoquakeauth: identify expects Hash for second parameter
Giuseppe Bilotta [Thu, 8 Jan 2009 14:15:19 +0000 (15:15 +0100)] 
quakeauth: identify expects Hash for second parameter

15 years agorot13: convert result to string
Giuseppe Bilotta [Thu, 8 Jan 2009 13:46:30 +0000 (14:46 +0100)] 
rot13: convert result to string

When core.reply_with_nick is active, m.reply expects the argument to be a
String. Do the conversion explicitly.

15 years agorfc2812: better handling of incomplete mode lines
Giuseppe Bilotta [Wed, 7 Jan 2009 22:39:33 +0000 (23:39 +0100)] 
rfc2812: better handling of incomplete mode lines

Sometimes the bot may receive incomplete or malformed mode lines. This
can be seen for example by kicking repeatedly and at very short
intervals the bot from a channel with +l set to some numbers (at least
on freenode).

We (don't) handle these malformed modelines by skipping them rather than
crashing.

15 years agoautorejoin: no-kick list
Giuseppe Bilotta [Wed, 7 Jan 2009 21:48:46 +0000 (22:48 +0100)] 
autorejoin: no-kick list

Botusers in the rejoin.no_kick_list config value can kick the bot without
risking being kicked when it rejoins

15 years agoautorejoin: option to kick the kicker
Giuseppe Bilotta [Wed, 7 Jan 2009 21:26:08 +0000 (22:26 +0100)] 
autorejoin: option to kick the kicker