Intermediate commits (oldest → newest):
- Merge branch 'main' of https://github.com/migatu/conjurer
- Restart radio script
- Radio restart serverside
- Merge branch 'main' of https://github.com/migatu/conjurer
- Typo fix ,
This commit is contained in:
2025-10-30 16:59:04 +01:00
parent aa0be5d905
commit 6f3eee90bb
9 changed files with 326 additions and 32 deletions
+32
View File
@@ -19,6 +19,7 @@ import shutil
import sys
import threading
import uuid
import subprocess
from datetime import datetime
from logging import handlers
from pathlib import Path, PurePath
@@ -1345,6 +1346,37 @@ async def max_weight(lista):
# *=========================================== Define Commands
@client.hybrid_command(
name="skip_track",
description="Przeskocz kawałek w radiu",
guild=discord.Object(id=664789470779932693),
)
async def skip_track(ctx):
async with ctx.typing():
allowed = False
for role in ctx.author.roles:
if role.name == "Thane":
allowed = True
if not allowed:
await ctx.send("Łapy precz od radia")
@client.hybrid_command(
name="zrestartuj_radio",
description="Komenda ktora uruchamia radio ponownie jakby się zawiesiło",
guild=discord.Object(id=664789470779932693),
)
async def zrestartuj_radio(ctx):
async with ctx.typing():
allowed = False
for role in ctx.author.roles:
if role.name == "Thane":
allowed = True
if not allowed:
await ctx.send("Łapy precz od radia")
else:
subprocess.call(['sh', './restart_radio.sh'])
@client.hybrid_command(
name="dej_co_ze_spotifaja",