Merge pull request #17 from KevinCaires/vinke

CHANGE version.
pull/3/head
Kevin Caires 3 years ago committed by GitHub
commit e2efd4d48a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -5,7 +5,7 @@
█ ▄ █ ▄▄▄█ ▄▄▄█ ▄ ██ █▄▄▄█ ▄▄▄█ █ ▄ █ ▄▄▄█ ▄▄▄█ ▄ ██ █▄▄▄█ ▄▄▄█
█ █ █ █ █▄▄▄█ █▄▄▄█ █▄█ █ █ █▄▄▄ █ █ █ █ █▄▄▄█ █▄▄▄█ █▄█ █ █ █▄▄▄
█▄█ █▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█ █▄█ █▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█▄▄▄▄▄▄▄█
Neeble version: 2022.08.20e Neeble version: 2022.08.21b
You can help the development of neeble in You can help the development of neeble in
https://github.com/KevinCaires/neeble https://github.com/KevinCaires/neeble
Thank you! Thank you!

@ -294,6 +294,11 @@ async def machine_info(bot: object, *args: str) -> str:
supported_args = [ supported_args = [
'network' 'network'
] ]
roles = [r.name for r in bot.author.roles]
if 'BotMan' not in roles:
return await bot.send("_And who the fuck do **YOU** think you are!?_.\n"\
"(You don't have the necessary role for this command)")
if not args: if not args:
embed.add_field(name='CPU', value=f'{Monitor.cpu_percent} %') embed.add_field(name='CPU', value=f'{Monitor.cpu_percent} %')
@ -302,6 +307,7 @@ async def machine_info(bot: object, *args: str) -> str:
embed.add_field(name='Disk total', value=f'{kbytes_to_gbytes(Monitor.disk_usage.total)} Gb') embed.add_field(name='Disk total', value=f'{kbytes_to_gbytes(Monitor.disk_usage.total)} Gb')
embed.add_field(name='Disk used', value=f'{kbytes_to_gbytes(Monitor.disk_usage.used)} Gb') embed.add_field(name='Disk used', value=f'{kbytes_to_gbytes(Monitor.disk_usage.used)} Gb')
embed.add_field(name='Disk free', value=f'{kbytes_to_gbytes(Monitor.disk_usage.free)} Gb') embed.add_field(name='Disk free', value=f'{kbytes_to_gbytes(Monitor.disk_usage.free)} Gb')
return await bot.send('**`Monitor`**', embed=embed)
if args[0] not in supported_args: if args[0] not in supported_args:
return await bot.send('The argument is not supported!') return await bot.send('The argument is not supported!')
@ -322,5 +328,3 @@ async def machine_info(bot: object, *args: str) -> str:
await bot.send(f'**`{io}`**', embed=embed) await bot.send(f'**`{io}`**', embed=embed)
return return
return await bot.send('**`Monitor`**', embed=embed)

Loading…
Cancel
Save