Improve code readability
parent
25c3d57fe2
commit
21384b9a35
12
bot.py
12
bot.py
|
@ -2,13 +2,13 @@
|
|||
# Code revised by BodgeMaster
|
||||
# Code Licensed under GPL 3.0
|
||||
|
||||
import sys, time, json
|
||||
|
||||
import discord
|
||||
from discord import app_commands
|
||||
import typing
|
||||
from discord.ext import commands
|
||||
import discord.utils
|
||||
import time
|
||||
import sys
|
||||
|
||||
BOOT_TIME = time.time()
|
||||
|
||||
|
@ -38,8 +38,12 @@ async def on_ready():
|
|||
|
||||
@client.tree.command(guild=discord.Object(id=813127962881818624), name="change_hostname")
|
||||
@app_commands.describe(distro='Assign yourself a role')
|
||||
async def distro(interaction: discord.Interaction, distro: typing.Literal['LFS', 'Kiss', 'Gentoo', 'Void', 'NixOS', 'Alpine', 'Arch', 'Arch-based', 'Red Hat', 'Bedrock', 'SuSE Based', 'OpenSuSE',
|
||||
'Debian', 'Debian based', 'Solus', 'Fedora', 'Ubuntu', 'Ubuntu Based', 'BSD', 'MacOS', 'Windows']):
|
||||
async def distro(interaction: discord.Interaction, distro: typing.Literal[
|
||||
'LFS', 'Kiss', 'Gentoo', 'Void', 'NixOS', 'Alpine',
|
||||
'Arch', 'Arch-based', 'Red Hat', 'Bedrock', 'SuSE Based',
|
||||
'OpenSuSE', 'Debian', 'Debian based', 'Solus', 'Fedora',
|
||||
'Ubuntu', 'Ubuntu Based', 'BSD', 'MacOS', 'Windows'
|
||||
]):
|
||||
user = interaction.user
|
||||
if distro == 'LFS':
|
||||
user = interaction.user
|
||||
|
|
Loading…
Reference in New Issue