Changes
Title
unchanged
The MrFisk IRC Bot
Category
unchanged
Others
Yii version
unchanged
Tags
unchanged
MrFisk, YiiBot, IRC, bot
Content
changed
Introduction
------------
MrFisk is a sleek little [bot](http://en.wikipedia.org/wiki/Internet_Relay_Chat_bot) hanging out in the official [#yii IRC channel](http://www.yiiframework.com/chat/) on [freenode](http://freenode.net/), meant to serve Yii users with documentation lookups and other things. This document intends to provide a summary of what MrFisk can do for you and how to use his fin^H^Heatures.
*Please note: MrFisk is currently (2012-08-24) in a non-finished but working state. He's been put online and joined #yii earlier than what was originally intented, simply due to the original YiiBot having been absent for a over a week. We needed a bot in the channel, and this one was close to ready. What is missing is primarily fuzzy matching of !{doc,api} queries, editing of factoids and some other new features currently not present in any of the bots.
This is planned to be addressed in the upcoming weeks.*
The `!faq <
keywordquery>` command
----------------------------
This command returns the factoid for the given
keywordquery. It's simply a quick way to make the bot spell out things we repeat often, and what not. *Note: Currently the factoid database is static, based on what could be found in YiiBot's online list.
It's going to be editable in the channel soon.*
A list of the current faqs/factoids can be found [here](http://fisk.cloud.tilaa.com/factoids.html).
The `!php <
keywordquery>` command
----------------------------
All this command does is return an URL to php.net's manual search result for the given
keywordquery.
The `!lmgtfy <query>` command
----------------------------
All this command does is return an URL to a search for the given query at lmgtfy.com.
The `!google <query>` command
----------------------------
All this command does is return the results from Googling the given query.
*Note: This command does not work with the addressing and inline commands feature (see below). The reason for this is that the Google functionality is provided by another plugin than MrFisk.*[...]
Multiple query words (quoting)
------------------------------
It's possible to supply more than one word in the query to most of the commands, by simply wrapping/delimiting the query in/with single or double quotes. For example `!php 'pattern matching'` and `!php "pattern matching"` would return the PHP manual URL for the search term "pattern matching".
To include a quote in the actual query without having it be used as a delimiter, there are two options; Either simply use the other type of quotes to delimit the query, or escape the quote with a backslash. For example, to provide a LMGTFY URL for a common phrase and retain its quoting, one could do `!lmgtfy '"date.timezone"'` or `!lmgtfy '\'date.timezone\''` - both works.
Within quoted queries, beginning and ending whitespace is removed. Please also note that unbalanced quotes will not match, they have to be a pair and of the same type (i.e. a mix of ' and " won't work). If the query isn't correctly quoted, it will be parsed as a one-word query.
Inline commands
---------------[...]
---------
**2013-11-05:**
Added support for multi-word queries in the `!faq`, `!php`, `!lmgtfy`, `!doc` and `!api` commands, both inline and not inline.
**2013-08-29:**
Added the `!lmgtfy` command.
**2013-01-16:**
Made nick addressing not trigger on `nick,` as it was often conflicting with messages like "btw, check out !faq foo".
**2012-08-27:**
Changed !api command to return an URL to the online API reference instead of to the source code for the result.