def main(): cli=bot( {"privmsg": handler.on_privmsg, "ctcp": handler.on_ctcp, "notice": lambda a, b, c, d: handler.on_privmsg(a, b, c, d, True), "": handler.unhandled}, botnick=config.NICK, account=config.USERNAME, username = config.USERNAME, password=config.PASSWORD, mserver=config.SERVER, channels=config.CHANNELS, addrchar=config.ADDRCHAR, ownercloak=config.ADMIN_CLOAKS, port=config.PORT, sasl=config.USE_SASL, debugchannel=config.DEBUG_CHANNEL, server_password=config.SERVER_PASSWORD, znc=config.USING_ZNC, admin_accounts=config.ADMIN_ACCOUNTS, handler=src.printer, needssl=config.SSL, connect_cb=handler.connect_callback, ) cli.MainLoop()
def main(): cli = IRCClient( {"privmsg": handler.on_privmsg, "notice": lambda a, b, c, d: handler.on_privmsg(a, b, c, d, True), "": handler.unhandled}, host=botconfig.HOST, port=botconfig.PORT, authname=botconfig.USERNAME, password=botconfig.PASS, nickname=botconfig.NICK, ident=botconfig.IDENT, real_name=botconfig.REALNAME, sasl_auth=botconfig.SASL_AUTHENTICATION, use_ssl=botconfig.USE_SSL, connect_cb=handler.connect_callback, stream_handler=src.stream, ) cli.mainLoop()
def main(): src.plog("Connecting to {0}:{1}{2}".format(botconfig.HOST, "+" if botconfig.USE_SSL else "", botconfig.PORT)) cli = IRCClient( {"privmsg": handler.on_privmsg, "notice": lambda a, b, c, d: handler.on_privmsg(a, b, c, d, True), "": handler.unhandled}, host=botconfig.HOST, port=botconfig.PORT, authname=botconfig.USERNAME, password=botconfig.PASS, nickname=botconfig.NICK, ident=botconfig.IDENT, real_name=botconfig.REALNAME, sasl_auth=botconfig.SASL_AUTHENTICATION, server_pass=botconfig.SERVER_PASS, use_ssl=botconfig.USE_SSL, connect_cb=handler.connect_callback, stream_handler=src.stream, ) cli.mainLoop()
def main(): src.plog("Connecting to {0}:{1}{2}".format( botconfig.HOST, "+" if botconfig.USE_SSL else "", botconfig.PORT)) cli = IRCClient( { "privmsg": handler.on_privmsg, "notice": lambda a, b, c, d: handler.on_privmsg(a, b, c, d, True), "": handler.unhandled }, host=botconfig.HOST, port=botconfig.PORT, authname=botconfig.USERNAME, password=botconfig.PASS, nickname=botconfig.NICK, ident=botconfig.IDENT, real_name=botconfig.REALNAME, sasl_auth=botconfig.SASL_AUTHENTICATION, server_pass=botconfig.SERVER_PASS, use_ssl=botconfig.USE_SSL, connect_cb=handler.connect_callback, stream_handler=src.stream, ) cli.mainLoop()