mirror of
https://github.com/SpiceBot/SpiceBot.git
synced 2026-11-10 21:50:59 -05:00
build option for regged nicks only
This commit is contained in:
parent
22170d5bdf
commit
56f6ea21fe
11
sopel_modules/SpiceBot/RegNicks.py
Normal file
11
sopel_modules/SpiceBot/RegNicks.py
Normal file
@ -0,0 +1,11 @@
|
||||
# coding=utf8
|
||||
from __future__ import unicode_literals, absolute_import, division, print_function
|
||||
"""
|
||||
This is the SpiceBot regnick system.
|
||||
"""
|
||||
|
||||
from sopel.config.types import StaticSection, ValidatedAttribute
|
||||
|
||||
|
||||
class SpiceBot_RegNicks_MainSection(StaticSection):
|
||||
announcenew = ValidatedAttribute('regnick', default=False)
|
||||
@ -13,6 +13,7 @@ from .Reddit import SpiceBot_Reddit_MainSection
|
||||
from .Sherlock import SpiceBot_Sherlock_MainSection
|
||||
from .Kick import SpiceBot_Kick
|
||||
from .osd import SpiceBot_OSD
|
||||
from .RegNicks import SpiceBot_RegNicks_MainSection
|
||||
|
||||
|
||||
def configure(config):
|
||||
@ -62,3 +63,6 @@ def configure(config):
|
||||
|
||||
config.define_section("SpiceBot_Sherlock", SpiceBot_Sherlock_MainSection, validate=False)
|
||||
config.SpiceBot_Sherlock.configure_setting('extra', 'SpiceBot_Sherlock API Extra directory')
|
||||
|
||||
config.define_section("SpiceBot_regnick", SpiceBot_RegNicks_MainSection, validate=False)
|
||||
config.SpiceBot_Channels.configure_setting('regnick', 'SpiceBot_Channels Announce New Channels')
|
||||
|
||||
@ -22,6 +22,7 @@ from .Gif import SpiceBot_Gif_MainSection
|
||||
from .DictComs import SpiceBot_DictComs_MainSection
|
||||
from .Sherlock import SpiceBot_Sherlock_MainSection
|
||||
from .AI import SpiceBot_AI_MainSection
|
||||
from .RegNicks import SpiceBot_RegNicks_MainSection
|
||||
|
||||
|
||||
def setup(bot):
|
||||
@ -64,6 +65,8 @@ def setup(bot):
|
||||
|
||||
setup_sherlock(bot)
|
||||
|
||||
setup_regnicks(bot)
|
||||
|
||||
|
||||
def setup_config(bot):
|
||||
logs.log('SpiceBot_Config', "Setting Up Configuration")
|
||||
@ -167,3 +170,8 @@ def setup_dictcoms(bot):
|
||||
|
||||
def setup_sherlock(bot):
|
||||
bot.config.define_section("SpiceBot_Sherlock", SpiceBot_Sherlock_MainSection, validate=False)
|
||||
|
||||
|
||||
def setup_regnicks(bot):
|
||||
bot.config.define_section("SpiceBot_regnick", SpiceBot_RegNicks_MainSection, validate=False)
|
||||
botconfig.define_section("SpiceBot_regnick", SpiceBot_RegNicks_MainSection, validate=False)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user