mirror of
https://github.com/yasirarism/MissKatyPyro.git
synced 2026-01-07 04:14:51 +00:00
ss
This commit is contained in:
parent
45eb99440f
commit
926caa9eb1
2 changed files with 13 additions and 2 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import textwrap
|
||||
import textwrap, logging
|
||||
from asyncio import gather
|
||||
from os import remove as hapus
|
||||
|
||||
|
|
@ -11,6 +11,7 @@ from misskaty.core.decorator.ratelimiter import ratelimiter
|
|||
from misskaty.helper.localization import use_chat_lang
|
||||
from misskaty.vars import COMMAND_HANDLER
|
||||
|
||||
LOGGER = logging.getLogger(__name__)
|
||||
|
||||
async def draw_meme_text(image_path, text):
|
||||
img = Image.open(image_path)
|
||||
|
|
@ -28,7 +29,7 @@ async def draw_meme_text(image_path, text):
|
|||
current_h, pad = 10, 5
|
||||
if upper_text:
|
||||
for u_text in textwrap.wrap(upper_text, width=15):
|
||||
low_test = draw.textlength(text=l_text, font=m_font)
|
||||
low_test = draw.textlength(text=u_text, font=m_font)
|
||||
LOGGER.info(low_test)
|
||||
u_width, u_height = draw.textlength(text=u_text, font=m_font)
|
||||
draw.text(
|
||||
|
|
|
|||
10
update.py
10
update.py
|
|
@ -7,6 +7,16 @@ import dotenv
|
|||
import requests
|
||||
from git import Repo
|
||||
|
||||
logging.basicConfig(
|
||||
level=INFO,
|
||||
format="[%(asctime)s - %(levelname)s] - %(name)s.%(funcName)s - %(message)s",
|
||||
datefmt="%d-%b-%y %H:%M:%S",
|
||||
handlers=[
|
||||
logging.handlers.RotatingFileHandler("MissKatyLogs.txt", mode="w+", maxBytes=1000000),
|
||||
logging.StreamHandler(),
|
||||
],
|
||||
)
|
||||
|
||||
LOGGER = logging.getLogger(__name__)
|
||||
|
||||
ENV_URL = os.environ.get("ENV_URL")
|
||||
|
|
|
|||
Loading…
Reference in a new issue