import logging
import logging.handlers
from pathlib import Path


formatter = logging.Formatter("%(asctime)s - %(name)s - %(levelname)s - %(message)s")
logger = logging.getLogger()

Path(".log/").mkdir(parents=True, exist_ok=True)

fileHandler = logging.FileHandler(".log/app.log")
fileHandler.setFormatter(formatter)
logger.addHandler(fileHandler)


fileHandler = logging.StreamHandler()
fileHandler.setFormatter(formatter)
logger.addHandler(fileHandler)


