Первый стрим

This commit is contained in:
2024-03-03 20:29:44 +04:00
parent 08eadb1292
commit 2649b9136a
10 changed files with 152 additions and 0 deletions

View File

@ -0,0 +1,11 @@
import subprocess
from aiogram.types import Message
async def execute_command(message: Message):
user_command = message.text.split()[1:]
print(user_command)
sub = subprocess.check_output(user_command)
# print(sub)
await message.answer(f"<pre><code>{sub.decode()}</code></pre>", parse_mode="HTML")