$ git clone https://github.com/MartinMatta/PyLog
$ cd PyLog
$ python setup.py install
test1.py
from PyLog.colors import *
from PyLog.log import Log
log = Log()
try:
import cv2
except ImportError:
log.e("no module named cv2", tag="ImportError")
test2.py
from PyLog.colors import *
from PyLog.log import Log
import os
class App(Log):
def __init__(self):
super().__init__(self)
def start(self):
self.i("start function") # info
if os.name == "posix":
# code
pass
else:
self.e("system not supported")
app = App()
app.start()