mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-08 10:54:15 +02:00
[improvement][arch] faster caching data process during initialization
This commit is contained in:
@@ -14,11 +14,10 @@ RE_CLEAN_NAME = re.compile(r'[+*?%]')
|
||||
def write(pkg: ArchPackage):
|
||||
data = pkg.get_data_to_cache()
|
||||
|
||||
if data:
|
||||
Path(pkg.get_disk_cache_path()).mkdir(parents=True, exist_ok=True)
|
||||
Path(pkg.get_disk_cache_path()).mkdir(parents=True, exist_ok=True)
|
||||
|
||||
with open(pkg.get_disk_data_path(), 'w+') as f:
|
||||
f.write(json.dumps(data))
|
||||
with open(pkg.get_disk_data_path(), 'w+') as f:
|
||||
f.write(json.dumps(data))
|
||||
|
||||
|
||||
def fill_icon_path(pkg: ArchPackage, icon_paths: List[str], only_exact_match: bool):
|
||||
|
||||
Reference in New Issue
Block a user