summaryrefslogtreecommitdiff
path: root/src/modules/echo.py
blob: 9510442a26c0d989920723e5ceadf73fb4480f7c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import asyncio

import main

client = None


@main.description("aka cat")
@main.name("echo")
@asyncio.coroutine
def echo(args, author, channel, message):
    yield from client.send_message(channel, content=author.mention + ': ' + args[0])


def setup(default_cmds, cclient):
    global client
    default_cmds += [echo]
    client = cclient