kameloso.plugins

Bits and bobs to register plugins to be instantiated on program startup/connect.

This should really only have to be used internally.

Modules

admin
module kameloso.plugins.admin

Package for the Admin plugin modules.

automode
module kameloso.plugins.automode

The Automode plugin handles automatically setting the modes of users in a channel. The common use-case is to have someone be automatically set to +o (operator) when joining.

bash
module kameloso.plugins.bash

The Bash plugin looks up bash.org quotes and reports them to the appropriate nickname or channel.

chatbot
module kameloso.plugins.chatbot

The Chatbot plugin is a diminishing collection of small, harmless features; like say/echo for simple repeating of text.

common
module kameloso.plugins.common

Package for the common plugin modules all plugins need.

counter
module kameloso.plugins.counter

A simple counter plugin.

hello
module kameloso.plugins.hello
Undocumented in source.
help
module kameloso.plugins.help

The Help plugin serves the help command, and nothing else at this point.

notes
module kameloso.plugins.notes

The Notes plugin allows for storing notes to offline users, to be replayed when they next join the channel.

oneliners
module kameloso.plugins.oneliners

The Oneliners plugin serves to provide custom commands, like !vods, !youtube, and any other static-reply !command (provided a prefix of "!").

pipeline
module kameloso.plugins.pipeline

The Pipeline plugin opens a Posix named pipe in a temporary directory or the current directory, to which you can pipe text and have it be sent verbatim to the server. There is also syntax to manually send bus messages to plugins.

poll
module kameloso.plugins.poll

The Poll plugin offers the ability to hold votes/polls in a channel. Any number of choices is supported, as long as they're more than one.

printer
module kameloso.plugins.printer

Package for the Printer plugin modules.

quotes
module kameloso.plugins.quotes

The Quotes plugin allows for saving and replaying user quotes.

same
module kameloso.plugins.same

This is an example toy plugin to showcase how one could be written to react to non-!command messages.

sedreplace
module kameloso.plugins.sedreplace

The SedReplace plugin imitates the UNIX sed tool, allowing for the replacement/substitution of text. It does not require the tool itself though, and will work on Windows too.

seen
module kameloso.plugins.seen

The Seen plugin implements "seen"; the ability for someone to query when a given nickname was last encountered online.

services
module kameloso.plugins.services

"Service"-level plugins, used to carry out tasks behind the scenes.

stopwatch
module kameloso.plugins.stopwatch

A simple stopwatch plugin. It offers the ability to start and stop timers, to get how much time passed between the creation of a stopwatch and the cessation of it.

time
module kameloso.plugins.time

A simple plugin for querying the time in different timezones.

timer
module kameloso.plugins.timer

Plugin offering announcement timers; routines that periodically sends lines of text to a channel.

twitch
module kameloso.plugins.twitch

Package for the Twitch plugin modules.

unittest_
module kameloso.plugins.unittest_

Unit test plugin.

webtitles
module kameloso.plugins.webtitles

The Webtitles plugin catches URLs pasted in a channel, follows them and reports back the title of the web page that was linked to.

Members

Aliases

priority
alias priority = Priority

Helper alias to use the proper style guide and still be able to instantiate Priority instances with UFCS.

Functions

instantiatePlugins
auto instantiatePlugins(IRCPluginState state)

Instantiates all plugins represented by a PluginRegistrationEntry in registeredPlugins.

registerPlugin
void registerPlugin(Priority priority, IRCPlugin function(IRCPluginState) ctor)

Registers a plugin to be instantiated on program startup/connect by creating a PluginRegistrationEntry and appending it to registeredPlugins.

Mixin templates

PluginRegistration
mixintemplate PluginRegistration(Plugin, Priority priority = 0.priority, string module_ = __MODULE__)

Mixes in a module constructor that registers the supplied IRCPlugin subclass to be instantiated on program startup/connect.

Structs

Priority
struct Priority

Embodies the notion of a priority at which a plugin should be instantiated, and as such, the order in which they will be called to handle events.

Examples

import kameloso.plugins;
import kameloso.plugins.common.core;

final class MyPlugin : IRCPlugin
{
    mixin IRCPluginImpl;
}

mixin ModuleRegistration;
import kameloso.plugins;

IRCPluginState state;
// state setup...

IRCPlugin[] plugins = instantiatePlugins(state);

Meta