Mwbot

mwbot is an IRC bot written by amidaniel to help on the #mediawiki support channel on the freenode IRC network. It also has its own channel, #mwbot. Source code is available at http://amidaniel.com/viewvc/trunk/MWBot/src/com/amidaniel/mwbot/?root=svn.

Quick help

 * !foo: displays factoid foo
 * !foo | quux: displays factoid foo, addressing the response to user quux
 * !foo is bar: defines factoid foo to be bar
 * !foo alias bar: defines foo as an alias for the factoid bar
 * !foo del: deletes factoid foo
 * @search foo.*: searches for the regular expression foo.* in all factoids
 * @trust host: trusts users on host, especially useful with IRC cloaks
 * @untrust host: removes trust for users on host
 * @trusted: lists trusted hosts

Parameters in factoids
Factoids can accept up to nine parameters, passed as space-delimited "arguments" to the factoid.


 * !foo is Hello, `1!: When expanded using "!foo bar", this will produce "Hello, bar!".
 * !foo is Hello, `e1!: URL-encodes the first parameter it receives. When expanded using "Hello, $wgGroupPermissions!", it produces "Hello, %24wgGroupPermissions!". Note that the parameters are encoded as UTF-8 which quite likely won't work for a lot of folks over IRC (may need to be changed).

See "!man" and "!info" for more realistic examples of how parameters are used.

Feature requests
Brainstorming sections. No guarantee anyone will ever look at this.


 * Support private messages
 * Probably not useful, given #mwbot. — Pathoschild 11:37:10, 12 November 2007 (UTC)
 * even there it meight get annoying to have someone play with the bot. Also, you have to know about it. Private messages is more intuitive, at least to IRC people. -- Duesentrieb ⇌ 17:00, 12 November 2007 (UTC)
 * Automatically search when no exact match is found
 * Automatically trust cloaked user addresses, depending on pattern (something like ^(wikipedia|wikimedia|mediawiki|wikia/))
 * Probably a bad idea; cloaks are given out rather liberally. — Pathoschild 11:37:10, 12 November 2007 (UTC)
 * dude, we are a wiki place :) Seriously, some channels even have the bot accept factoids from anyone. -- Duesentrieb ⇌ 17:00, 12 November 2007 (UTC)
 * Yes, but those bots are usually for play. It would suck to have someone overwrite your detailed explanation of a fix with "LOLZ BURN", unless we implement a history feature. ;) — Pathoschild 19:32:54, 15 November 2007 (UTC)
 * fair enough. point taken -- Duesentrieb ⇌ 19:51, 15 November 2007 (UTC)
 * Meh, implemented. Will now match regexes. AmiDaniel 09:29, 15 December 2007 (UTC)
 * magic factoids for config settings and manual pages: !$wgXXX -> http://www.mediawiki.org/wiki/Manual:$wgXXX
 * Done with parameter substitution. Try "!man $wgXX". AmiDaniel 09:29, 15 December 2007 (UTC)
 * List aliases. MinuteElectron 11:45, 18 November 2007 (UTC)