WIP #51
This commit is contained in:
parent
012feae29c
commit
a6a7eb07bc
3 changed files with 9 additions and 9 deletions
|
@ -6,7 +6,7 @@ stages:
|
||||||
|
|
||||||
variables:
|
variables:
|
||||||
GL_TOKEN: $GL_TOKEN
|
GL_TOKEN: $GL_TOKEN
|
||||||
VERSION: '0.2.4'
|
VERSION: '0.2.5'
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
stage: deploy
|
stage: deploy
|
||||||
|
|
|
@ -272,13 +272,13 @@ class Audio(commands.Cog, name="Commandes Audio"):
|
||||||
@commands.command()
|
@commands.command()
|
||||||
async def find(self, ctx, query):
|
async def find(self, ctx, query):
|
||||||
"""Cherche un son dans la bibliothèque"""
|
"""Cherche un son dans la bibliothèque"""
|
||||||
if query:
|
|
||||||
query = query.lower()
|
query = query.lower()
|
||||||
audio_files = [f for f in Path(self.audio_path + '/').glob('**/*.mp3') if query in str(f).lower()]
|
audio_files = [f for f in Path(self.audio_path + '/').glob('**/*.mp3') if query in str(f).lower()]
|
||||||
if not audio_files:
|
if not audio_files:
|
||||||
await ctx.channel.send("%s not found" % query)
|
await ctx.channel.send("%s not found" % query)
|
||||||
else:
|
else:
|
||||||
await ctx.channel.send("\n".join(audio_files))
|
for file in audio_files:
|
||||||
|
await ctx.channel.send("```"+str(file)+"```")
|
||||||
|
|
||||||
@commands.command()
|
@commands.command()
|
||||||
async def joke(self, ctx, folder=None):
|
async def joke(self, ctx, folder=None):
|
||||||
|
|
|
@ -61,6 +61,6 @@ setup(
|
||||||
test_suite='tests',
|
test_suite='tests',
|
||||||
tests_require=test_requirements,
|
tests_require=test_requirements,
|
||||||
url='https://github.com/None/kabot',
|
url='https://github.com/None/kabot',
|
||||||
version='0.2.4',
|
version='0.2.5',
|
||||||
zip_safe=False,
|
zip_safe=False,
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue