Style updated

This commit is contained in:
Dimitris Zlatanidis 2024-04-20 20:46:42 +03:00
parent cb14312e04
commit 3df6c0af1e

View file

@ -56,17 +56,23 @@ class CheckUpdates(Configs):
queue.put(self.error_connected)
def save_the_compares(self, repo: str) -> None:
local_chg_txt: Path = Path(self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['changelog_txt'])
repo_chg_txt: str = (f"{self.repos.repositories[repo]['mirror_changelog']}"
f"{self.repos.repositories[repo]['changelog_txt']}")
local_chg_txt: Path = Path(
self.repos.repositories[repo]['path'],
self.repos.repositories[repo]['changelog_txt']
)
repo_chg_txt: str = (
f"{self.repos.repositories[repo]['mirror_changelog']}"
f"{self.repos.repositories[repo]['changelog_txt']}"
)
repo_data_file: Path = Path(self.repos.repositories[repo]['path'],
self.repos.data_json)
if not repo_data_file.is_file():
self.compare[repo] = True
else:
self.compare[repo] = self.compare_the_changelogs(local_chg_txt, repo_chg_txt)
self.compare[repo] = self.compare_the_changelogs(
local_chg_txt, repo_chg_txt)
def compare_the_changelogs(self, local_chg_txt: Path, repo_chg_txt: str) -> bool:
local_size: int = 0