changed extensions to cogs, removed mentions of plugins/extensions
This commit is contained in:
parent
bdcdd87348
commit
0e5cb9dd0f
17 changed files with 6 additions and 6 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -1,5 +1,5 @@
|
||||||
phixxy.com/
|
phixxy.com/
|
||||||
extensions/__pycache__/
|
cogs/__pycache__/
|
||||||
data/
|
data/
|
||||||
logs/
|
logs/
|
||||||
src/__pycache__/
|
src/__pycache__/
|
||||||
|
|
|
||||||
10
src/bot.py
10
src/bot.py
|
|
@ -12,13 +12,13 @@ logger = src.logger.logger_setup()
|
||||||
|
|
||||||
|
|
||||||
async def load_cogs(bot: commands.Bot, cog_path: str) -> None:
|
async def load_cogs(bot: commands.Bot, cog_path: str) -> None:
|
||||||
for plugin_file in os.listdir(cog_path):
|
for cog_file in os.listdir(cog_path):
|
||||||
if plugin_file[-3:] == '.py':
|
if cog_file[-3:] == '.py':
|
||||||
try:
|
try:
|
||||||
await bot.load_extension(f'extensions.{plugin_file[:-3]}')
|
await bot.load_extension(f'extensions.{cog_file[:-3]}')
|
||||||
logger.info(f"Successfully loaded plugin {plugin_file}")
|
logger.info(f"Successfully loaded cog {cog_file}")
|
||||||
except:
|
except:
|
||||||
logger.exception(f"Failed to load plugin {plugin_file}")
|
logger.exception(f"Failed to load cog {cog_file}")
|
||||||
|
|
||||||
@bot.event
|
@bot.event
|
||||||
async def on_ready():
|
async def on_ready():
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue