Created
August 27, 2012 17:02
-
-
Save Motoma/3490392 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
import template | |
class IRCScript(template.IRCScript): | |
def privmsg(self, user, channel, msg): | |
print(' [%s] <%s> %s' % (channel, user, msg)) | |
def action(self, user, channel, data): | |
print(' [%s] * %s %s' % (channel, user, data)) | |
def userJoined(self, user, channel): | |
print('J[%s] * %s has joined the channel.' % (channel, user)) | |
def userLeft(self, user, channel): | |
print('L[%s] * %s has left the channel.' % (channel, user)) | |
def userQuit(self, user, quitMessage): | |
print('Q * %s has quit (%s).' % (user, quitMessage)) | |
def userKicked(self, kickee, channel, kicker, message): | |
print('K[%s] * %s has kicked %s from the channel (%s).' % (channel, kicker, kickee, message)) | |
def msg(self, channel, msg): | |
print(' [%s] <%s> %s' % (channel, self.nickname, msg)) | |
def describe(self, channel, data): | |
print(' [%s] * You %s' % (channel, data)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment