Tested and enhanced scanext(). Should be working.
This commit is contained in:
parent
df1040dfec
commit
9824af4761
1 changed files with 3 additions and 0 deletions
|
@ -79,9 +79,12 @@ async def sync(ctx: commands.Context, guilds: commands.Greedy[discord.Object],
|
||||||
# loading extensions ...
|
# loading extensions ...
|
||||||
# TODO: Test this.
|
# TODO: Test this.
|
||||||
async def scanext():
|
async def scanext():
|
||||||
|
print("Loading extensions:")
|
||||||
for filename in os.listdir("./ext"):
|
for filename in os.listdir("./ext"):
|
||||||
if filename.endswith(".py"):
|
if filename.endswith(".py"):
|
||||||
await bot.load_extension(f"ext.{filename[:-3]}")
|
await bot.load_extension(f"ext.{filename[:-3]}")
|
||||||
|
print(f'Loaded: {filename}')
|
||||||
|
print('\n')
|
||||||
|
|
||||||
|
|
||||||
async def main():
|
async def main():
|
||||||
|
|
Loading…
Add table
Reference in a new issue