mirror of
https://github.com/th3r00t/pyShelf.git
synced 2026-04-28 01:59:35 -04:00
Run black on all files
This commit is contained in:
@@ -7,25 +7,26 @@ class Config:
|
||||
"""
|
||||
Main System Configuration
|
||||
"""
|
||||
|
||||
_fp = "config.json"
|
||||
print(os.path)
|
||||
|
||||
def __init__(self, root=os.path.abspath('../')):
|
||||
def __init__(self, root=os.path.abspath("../")):
|
||||
_data = self.open_file(root)
|
||||
self.book_path = _data['BOOKPATH']
|
||||
self.TITLE = _data['TITLE']
|
||||
self.VERSION = _data['VERSION']
|
||||
self.book_path = _data["BOOKPATH"]
|
||||
self.TITLE = _data["TITLE"]
|
||||
self.VERSION = _data["VERSION"]
|
||||
self.TITLE = self.TITLE + " ver " + self.VERSION
|
||||
self.book_shelf = _data['BOOKSHELF']
|
||||
self.book_shelf = _data["BOOKSHELF"]
|
||||
# self.catalogue_db = "data/catalogue.db"
|
||||
self.catalogue_db = root+'/'+_data['DATABASE']
|
||||
self.catalogue_db = root + "/" + _data["DATABASE"]
|
||||
self.file_array = [
|
||||
self.book_shelf,
|
||||
self.catalogue_db,
|
||||
]
|
||||
]
|
||||
self.auto_scan = True
|
||||
|
||||
def open_file(self, root):
|
||||
with open(root+'/'+self._fp, "r") as read_file:
|
||||
with open(root + "/" + self._fp, "r") as read_file:
|
||||
data = json.load(read_file)
|
||||
return data
|
||||
|
||||
Reference in New Issue
Block a user