Download the PHP package whisller/irc-bot-bundle without Composer

On this page you can find all versions of the php package whisller/irc-bot-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package irc-bot-bundle

IrcBotBundle

Build Status

Installation

  1. Download IrcBotBundle
  2. Enable the bundle
  3. Configure server, user
  4. Launch the IrcBot!

Step 1: Download IrcBotBundle

Now tell composer to download the bundle by running the command:

Composer will install the bundle to your project's vendor/whisller directory.

Step 2: Enable the bundle

Enable the bundle in the kernel:

Step 3: Configure server, user

Basic configuration:

Advanced configuration:

Step 4: Launch the IrcBot!

Write your own bot's command.

  1. Write listener
  2. Register your listener
  3. Use your command

When you want to write your own command it is really simple, because IrcBotBundle is working on Event Dispatcher.

So one thing you need to do is catch command event, and handle it.

Best way to learn something is to see how does it work. So lets write simple command, which will be saying "Hi {user}!"

Step 1: Write listener

Step 2: Register your listener

As you can see event name is "whisnet_irc_bot.bot_command_hello", bundle is listening on PRIVMSG message from server, then searching in it for string defined in "whisnet_irc_bot.command_prefix".

If the "whisnet_irc_bot.command_prefix" string gonna by found, then bundle is trying to parse everything after it to read command name and arguments for pass to "BotCommandFoundEvent".

E.g. "!bot hello whisller" will be parsed as:

And then it trigger an event "whisnet_irc_bot.bot_command_hello".

Step 3: Use your command

Events list

IrcBotBundle events

This event is triggered after connection to the server is established. The example of use this event you can find in Whisnet\IrcBotBundle\EventListener\Plugins\Core\LoadUserCoreListener class.

Server events

Bundle is triggering events based on server messages. E.g.

and so on.

The event name is really simple, it is based on prefix "whisnet_irc_bot.irccommand" and a type of message sent by server, e.g. "PRIVMSG". So you can listen on all events sent by server to make your own extends of bundle.

All list of commands you can find on http://tools.ietf.org/html/rfc2812

Bot commands

If Whisnet\IrcBotBundle\EventListener\Irc\Messages\PrivMsgListener::onData decide that message wrote on channel are a irc bot command then it trigger an event "whisnet_irc_bot.bot_command_COMMANDNAME" e.g. whisnet_irc_bot.bot_command_time, whisnet_irc_bot.bot_command_seen.


All versions of irc-bot-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.3
symfony/framework-bundle Version 2.*
symfony/console Version 2.*
symfony/validator Version 2.*
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package whisller/irc-bot-bundle contains the following files

Loading the files please wait ....