From 95848c31630e1b8d82a1f1f4a7e6b0d42ab88033 Mon Sep 17 00:00:00 2001 From: bmintz Date: Tue, 31 Jul 2018 21:05:23 -0500 Subject: [PATCH] add description --- bot.py | 9 ++++++--- config.example.py | 5 +++++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/bot.py b/bot.py index 50ff06c..6f7b2e4 100755 --- a/bot.py +++ b/bot.py @@ -13,13 +13,16 @@ logger.setLevel(logging.INFO) class Bot(commands.AutoShardedBot): def __init__(self, **kwargs): - super().__init__(command_prefix=commands.when_mentioned, **kwargs) - with open('config.py') as f: self.config = eval(f.read(), {}) + super().__init__( + command_prefix=commands.when_mentioned, + description=self.config.get('description', ''), + **kwargs) + for cog in self.config['cogs']: - self.load_extension(cog) + self.load_extension(cog) def run(self): super().run(self.config['tokens'].pop('discord')) diff --git a/config.example.py b/config.example.py index 6253987..cf166e0 100644 --- a/config.example.py +++ b/config.example.py @@ -1,4 +1,9 @@ { + 'description': + 'Emote Manager lets you manage custom server emotes from your phone. ' + 'NOTE: Most commands will be unavailable until both you and the bot have the ' + '"Manage Emojis" permission.', + 'cogs': ( 'cogs.emote', 'cogs.meta',