mirror of
https://github.com/Floriansylvain/Risitas_BOT.git
synced 2026-08-19 11:43:16 +02:00
Update main.py
This commit is contained in:
+3
-2
@@ -48,8 +48,9 @@ async def unloadext(ctx, extension):
|
|||||||
@bot.command(hidden=True)
|
@bot.command(hidden=True)
|
||||||
@commands.is_owner()
|
@commands.is_owner()
|
||||||
async def update(ctx):
|
async def update(ctx):
|
||||||
result = os.popen('git pull')
|
result = str(os.popen('git pull').read())
|
||||||
await ctx.send(str(result.read()))
|
await ctx.send('``' + result + '``')
|
||||||
|
if 'Already up to date' not in result:
|
||||||
os.execl(sys.executable, os.path.abspath(__file__), *sys.argv)
|
os.execl(sys.executable, os.path.abspath(__file__), *sys.argv)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user