moved functions to their own modules
deleted unused _essentials.py
This commit is contained in:
parent
b023724e09
commit
b1beb57dfc
5 changed files with 88 additions and 192 deletions
|
|
@ -2,6 +2,15 @@ import logging
|
|||
import os
|
||||
from logging.config import dictConfig
|
||||
|
||||
def logger_setup():
|
||||
if not os.path.isdir("logs"):
|
||||
os.mkdir("logs")
|
||||
with open("logs/info.log", "a") as f:
|
||||
pass
|
||||
logger = logging.getLogger("bot")
|
||||
return logger
|
||||
|
||||
|
||||
LOGGING_CONFIG = {
|
||||
"version": 1,
|
||||
"disabled_existing_loggers": False,
|
||||
|
|
@ -41,8 +50,4 @@ LOGGING_CONFIG = {
|
|||
},
|
||||
}
|
||||
|
||||
if not os.path.isdir("logs"):
|
||||
os.mkdir("logs")
|
||||
with open("logs/info.log", "a") as f:
|
||||
pass
|
||||
dictConfig(LOGGING_CONFIG)
|
||||
Loading…
Add table
Add a link
Reference in a new issue