add invite command
This commit is contained in:
parent
016859897f
commit
6c8aec3a08
2
main.py
2
main.py
@ -27,7 +27,7 @@ bot.load_extension('miyu_bot.commands.cogs.utility')
|
|||||||
@bot.event
|
@bot.event
|
||||||
async def on_ready():
|
async def on_ready():
|
||||||
logging.getLogger(__name__).info(f'Current server count: {len(bot.guilds)}')
|
logging.getLogger(__name__).info(f'Current server count: {len(bot.guilds)}')
|
||||||
await bot.change_presence(activity=discord.Game(name='test'))
|
await bot.change_presence(activity=discord.Game(name='https://discord.gg/TThMwrAZTR'))
|
||||||
|
|
||||||
|
|
||||||
bot.run(bot_token)
|
bot.run(bot_token)
|
||||||
|
@ -20,6 +20,13 @@ class Utility(commands.Cog):
|
|||||||
async def similarity_score(self, ctx: commands.Context, source: str, target: str):
|
async def similarity_score(self, ctx: commands.Context, source: str, target: str):
|
||||||
await ctx.send(str(FuzzyMatcher().score(romanize(source), romanize(target))))
|
await ctx.send(str(FuzzyMatcher().score(romanize(source), romanize(target))))
|
||||||
|
|
||||||
|
@commands.command(name='invite',
|
||||||
|
aliases=[],
|
||||||
|
description='Sends the bot invite.',
|
||||||
|
help='!invite')
|
||||||
|
async def invite(self, ctx: commands.Context):
|
||||||
|
await ctx.send('https://discord.com/api/oauth2/authorize?client_id=789314370999287808&permissions=388160&scope=bot')
|
||||||
|
|
||||||
|
|
||||||
def setup(bot):
|
def setup(bot):
|
||||||
bot.add_cog(Utility(bot))
|
bot.add_cog(Utility(bot))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user