mirror of
https://github.com/th3r00t/pyShelf.git
synced 2026-04-28 01:59:35 -04:00
Implemented new logging functions, refactored to suit.
This commit is contained in:
@@ -11,13 +11,13 @@ from .lib.storage import Storage
|
||||
sys.path.append(os.path.abspath("."))
|
||||
|
||||
|
||||
def MakeCollections(root):
|
||||
def MakeCollections(root, **kwargs):
|
||||
_t1 = time.time()
|
||||
config = Config(root) # Get configuration settings
|
||||
try: config = kwargs['config']
|
||||
except KeyError as e: config = Config(root)
|
||||
# InitFiles(config.file_array) # Initialize file system
|
||||
_storage = Storage(config)
|
||||
_storage.make_collections()
|
||||
_t2 = time.time()
|
||||
scan_time = round(_t2 - _t1)
|
||||
print("Collections Made.")
|
||||
print("Time %s seconds" % scan_time)
|
||||
config.logger.info("Collections made in {}".format(scan_time))
|
||||
|
||||
Reference in New Issue
Block a user