From 4f9ebdbe5d0462c1765180cb9e544b8298d106f4 Mon Sep 17 00:00:00 2001 From: Dimitris Zlatanidis Date: Thu, 18 May 2023 11:05:32 +0300 Subject: [PATCH] Updated for install data --- slpkg/update_repository.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/slpkg/update_repository.py b/slpkg/update_repository.py index fb9a5b0c..6f900e66 100644 --- a/slpkg/update_repository.py +++ b/slpkg/update_repository.py @@ -78,17 +78,20 @@ class UpdateRepository(Configs): if self.option_for_repository: if not self.option_for_install_data: - print(f"Downloading the '{self.green}{self.repository}{self.endc}' repository " - f"in the '{self.repos.repositories[self.repository]['path']}' folder, please wait...\n") + self.view_downloading_message(self.repository) repositories[self.repository]() else: - for repo, value in self.repos_for_update.items(): - if value: - print(f"Downloading the '{self.green}{repo}{self.endc}' repository " - f"in the '{self.repos.repositories[repo]['path']}' folder, please wait...\n") + for repo, update in self.repos_for_update.items(): + if update: + if not self.option_for_install_data: + self.view_downloading_message(repo) repositories[repo]() print() + def view_downloading_message(self, repo: str) -> None: + print(f"Downloading the '{self.green}{repo}{self.endc}' repository " + f"in the '{self.repos.repositories[repo]['path']}' folder, please wait...\n") + def slack_repository(self): if not self.option_for_install_data: urls: list = []