WIP: Refactor Aurora (3.0.0) #29
1 changed files with 8 additions and 3 deletions
|
@ -1224,7 +1224,12 @@ class Aurora(commands.Cog):
|
|||
error("Please provide a valid GalacticBot moderation export file.")
|
||||
)
|
||||
|
||||
@aurora.command(aliases=["dtc", "dt", "datetimeconvert"])
|
||||
@aurora.group(autohelp=True, name="convert")
|
||||
async def aurora_convert(self, ctx: commands.Context):
|
||||
"""Convert strings to various Python objects."""
|
||||
pass
|
||||
|
||||
@aurora_convert.command(aliases=["dt"])
|
||||
async def datetime(self, ctx: commands.Context, *, date: str) -> None:
|
||||
"""Convert a string to a datetime object.
|
||||
|
||||
|
@ -1243,7 +1248,7 @@ class Aurora(commands.Cog):
|
|||
if e == OverflowError:
|
||||
await ctx.send(error("Date is too far in the future!"))
|
||||
|
||||
@aurora.command(aliases=["tdc", "td", "timedeltaconvert"])
|
||||
@aurora_convert.command(aliases=["td"])
|
||||
async def timedelta(self, ctx: commands.Context, *, duration: str) -> None:
|
||||
"""Convert a string to a timedelta.
|
||||
|
||||
|
@ -1260,7 +1265,7 @@ class Aurora(commands.Cog):
|
|||
return
|
||||
await ctx.send(f"`{parsed_time}`")
|
||||
|
||||
@aurora.command(aliases=["rdc", "rd", "relativedeltaconvert"])
|
||||
@aurora_convert.command(aliases=["rd"])
|
||||
async def relativedelta(self, ctx: commands.Context, *, duration: str) -> None:
|
||||
"""Convert a string to a relativedelta.
|
||||
|
||||
|
|
Loading…
Reference in a new issue