add nickserv functionality
This commit is contained in:
parent
79cd7d73c4
commit
205e112718
|
@ -74,6 +74,7 @@ SCHEDULE_EVENT_NOTIFICATION_MINUTES=10
|
||||||
# irc bot settings
|
# irc bot settings
|
||||||
IRCBOT_CHECK_MESSAGE_INTERVAL_SECONDS=60
|
IRCBOT_CHECK_MESSAGE_INTERVAL_SECONDS=60
|
||||||
IRCBOT_NICK='{{ django_ircbot_nickname }}'
|
IRCBOT_NICK='{{ django_ircbot_nickname }}'
|
||||||
|
IRCBOT_NICKSERV_PASSWORD='{{ django_ircbot_nickserv_password }}'
|
||||||
IRCBOT_SERVER_HOSTNAME='{{ django_ircbot_server }}'
|
IRCBOT_SERVER_HOSTNAME='{{ django_ircbot_server }}'
|
||||||
IRCBOT_SERVER_PORT=6697
|
IRCBOT_SERVER_PORT=6697
|
||||||
IRCBOT_SERVER_USETLS=True
|
IRCBOT_SERVER_USETLS=True
|
||||||
|
|
|
@ -59,6 +59,14 @@ class Plugin(object):
|
||||||
def on_kick(self, **kwargs):
|
def on_kick(self, **kwargs):
|
||||||
logger.debug("inside on_kick(), kwargs: %s" % kwargs)
|
logger.debug("inside on_kick(), kwargs: %s" % kwargs)
|
||||||
|
|
||||||
|
|
||||||
|
@irc3.event(r'(@(?P<tags>\S+) )?:(?P<ns>NickServ)!NickServ@services.baconsvin.org' r' NOTICE (?P<nick>irc3) :This nickname is registered.*')
|
||||||
|
def needs_nickserv_identify(self, **kwargs):
|
||||||
|
"""Triggered when we need to identify with nickserv after connecting"""
|
||||||
|
logger.info("Nickserv identify needed, fixing...")
|
||||||
|
bot.privmsg("NickServ@services.baconsvin.org", "identify %s %s" % (settings.IRCBOT_NICK, settings.IRCBOT_NICKSERV_PASSWORD))
|
||||||
|
|
||||||
|
|
||||||
###############################################################################################
|
###############################################################################################
|
||||||
### custom irc3 methods
|
### custom irc3 methods
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue