base.requirements.txt
This commit is contained in:
parent
79c7113bce
commit
b96dc477c0
@ -5,6 +5,8 @@ ENV v6root=/v6data
|
||||
RUN apt-get update
|
||||
RUN apt-get install -y libopus0 opus-tools ffmpeg
|
||||
RUN apt-get install -y tor
|
||||
COPY base.requirements.txt base.requirements.txt
|
||||
RUN pip install -r base.requirements.txt
|
||||
COPY requirements.txt requirements.txt
|
||||
RUN pip install -r requirements.txt
|
||||
COPY v6d3music v6d3music
|
||||
|
3
base.requirements.txt
Normal file
3
base.requirements.txt
Normal file
@ -0,0 +1,3 @@
|
||||
aiohttp~=3.7.4.post0
|
||||
discord.py[voice]~=1.7.3
|
||||
youtube_dl~=2021.12.17
|
@ -1,6 +1,6 @@
|
||||
aiohttp~=3.7.4.post0
|
||||
discord.py[voice]~=1.7.3
|
||||
youtube_dl~=2021.12.17
|
||||
git+https://gitea.parrrate.ru/PTV/v6d1tokens.git@d382a0aa59525c40009bc9e6c30aaec3e506062a
|
||||
git+https://gitea.parrrate.ru/PTV/v6d2ctx.git@096314b9bbb6153a9a75afcc16ddf7833384df18
|
||||
git+https://gitea.parrrate.ru/PTV/adaas.git@2052448b19f895dee5cec9eaec470243d130d253
|
||||
ptvp35 @ git+https://gitea.parrrate.ru/PTV/ptvp35.git@c9cdbf86a67eaf817baf0bc23e0440b54c070362
|
||||
v6d0auth @ git+https://gitea.parrrate.ru/PTV/v6d0auth.git@c4b7a4900d36cb74b5aa544864cbbd3125415bb4
|
||||
v6d1tokens @ git+https://gitea.parrrate.ru/PTV/v6d1tokens.git@22c9784d20d6d9d860d4f1c0da41254db17ab9a2
|
||||
v6d2ctx @ git+https://gitea.parrrate.ru/PTV/v6d2ctx.git@2f0ac33c0228d43b9263ca31f584be2f96ad84eb
|
||||
rainbowadn @ git+https://gitea.parrrate.ru/PTV/rainbowadn.git@add1e7cdbf817811d4b85baec63ed0b87ae96dae
|
||||
adaas @ git+https://gitea.parrrate.ru/PTV/adaas.git@a598939c635e91c1b8482c5846b23d6442bcaa8e
|
||||
|
@ -50,6 +50,7 @@ async def skip(ctx: Context, args: list[str]) -> None:
|
||||
`skip [first] [last]`
|
||||
''', 'help'
|
||||
)
|
||||
assert ctx.member is not None
|
||||
match args:
|
||||
case []:
|
||||
queue = await queue_for(ctx, create=False, force_play=False)
|
||||
@ -121,6 +122,7 @@ async def default(ctx: Context, args: list[str]) -> None:
|
||||
`default none`
|
||||
''', 'help'
|
||||
)
|
||||
assert ctx.guild is not None
|
||||
match args:
|
||||
case ['-', effects]:
|
||||
pass
|
||||
@ -148,6 +150,7 @@ async def queue_(ctx: Context, args: list[str]) -> None:
|
||||
`queue pause`
|
||||
''', 'help'
|
||||
)
|
||||
assert ctx.member is not None
|
||||
match args:
|
||||
case []:
|
||||
await ctx.long(
|
||||
@ -176,6 +179,7 @@ async def swap(ctx: Context, args: list[str]) -> None:
|
||||
`swap a b`
|
||||
''', 'help'
|
||||
)
|
||||
assert ctx.member is not None
|
||||
match args:
|
||||
case [a, b] if a.isdecimal() and b.isdecimal():
|
||||
a, b = int(a), int(b)
|
||||
@ -191,6 +195,7 @@ async def move(ctx: Context, args: list[str]) -> None:
|
||||
`move a b`
|
||||
''', 'help'
|
||||
)
|
||||
assert ctx.member is not None
|
||||
match args:
|
||||
case [a, b] if a.isdecimal() and b.isdecimal():
|
||||
a, b = int(a), int(b)
|
||||
@ -206,6 +211,7 @@ async def volume_(ctx: Context, args: list[str]) -> None:
|
||||
`volume volume`
|
||||
''', 'help'
|
||||
)
|
||||
assert ctx.member is not None
|
||||
match args:
|
||||
case [volume]:
|
||||
volume = float(volume)
|
||||
|
@ -2,7 +2,8 @@ import discord
|
||||
from v6d2ctx.context import Explicit
|
||||
|
||||
|
||||
def assert_admin(member: discord.Member):
|
||||
def assert_admin(member: discord.Member | None):
|
||||
assert member is not None
|
||||
permissions: discord.Permissions = member.guild_permissions
|
||||
if not permissions.administrator:
|
||||
raise Explicit('not an administrator')
|
||||
|
Loading…
Reference in New Issue
Block a user