Add epub support

This commit is contained in:
2024-03-08 17:08:58 +08:00
parent f61a2af57d
commit 9cfb73759b
8 changed files with 433 additions and 1 deletions

View File

@@ -35,6 +35,8 @@ class Config:
if key in self._data:
return self._data[key]
else:
if default is not None:
self._data[key] = default
return default
@cached_property
@@ -90,6 +92,10 @@ class Config:
temp = temp.replace(f'<{k}>', str(chapter[k]))
return temp
@cached_property
def img_cache_dir(self):
return self.get_arg('img_cache_dir', 'img_cache')
@cached_property
def key(self):
return self.get_arg('key', None)