Updated for methods

This commit is contained in:
Dimitris Zlatanidis 2023-04-18 17:24:28 +03:00
parent 3685a4e369
commit 9696988952

View file

@ -115,7 +115,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.slack_repo_name)
self.delete_bin_database_data(self.repos.slack_repo_name)
self.delete_last_updated(self.repos.slack_repo_name)
self.data.install_slack_data()
print()
@ -145,7 +145,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.slack_extra_repo_name)
self.delete_bin_database_data(self.repos.slack_extra_repo_name)
self.delete_last_updated(self.repos.slack_extra_repo_name)
self.data.install_slack_extra_data()
print()
@ -175,7 +175,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.slack_patches_repo_name)
self.delete_bin_database_data(self.repos.slack_patches_repo_name)
self.delete_last_updated(self.repos.slack_patches_repo_name)
self.data.install_slack_patches_data()
print()
@ -201,7 +201,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.alien_repo_name)
self.delete_bin_database_data(self.repos.alien_repo_name)
self.delete_last_updated(self.repos.alien_repo_name)
self.data.install_alien_data()
print()
@ -228,7 +228,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.multilib_repo_name)
self.delete_bin_database_data(self.repos.multilib_repo_name)
self.delete_last_updated(self.repos.multilib_repo_name)
self.data.install_multilib_data()
print()
@ -255,7 +255,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.restricted_repo_name)
self.delete_bin_database_data(self.repos.restricted_repo_name)
self.delete_last_updated(self.repos.restricted_repo_name)
self.data.install_restricted_data()
print()
@ -281,7 +281,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.gnome_repo_name)
self.delete_bin_database_data(self.repos.gnome_repo_name)
self.delete_last_updated(self.repos.gnome_repo_name)
self.data.install_gnome_data()
print()
@ -311,7 +311,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.msb_repo_name)
self.delete_bin_database_data(self.repos.msb_repo_name)
self.delete_last_updated(self.repos.msb_repo_name)
self.data.install_msb_data()
print()
@ -341,7 +341,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.csb_repo_name)
self.delete_bin_database_data(self.repos.csb_repo_name)
self.delete_last_updated(self.repos.csb_repo_name)
self.data.install_csb_data()
print()
@ -368,7 +368,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.conraid_repo_name)
self.delete_bin_database_data(self.repos.conraid_repo_name)
self.delete_last_updated(self.repos.conraid_repo_name)
self.data.install_conraid_data()
print()
@ -395,7 +395,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.slackonly_repo_name)
self.delete_bin_database_data(self.repos.slackonly_repo_name)
self.delete_last_updated(self.repos.slackonly_repo_name)
self.data.install_slackonly_data()
print()
@ -422,7 +422,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.salixos_repo_name)
self.delete_bin_database_data(self.repos.salixos_repo_name)
self.delete_last_updated(self.repos.salixos_repo_name)
self.data.install_salixos_data()
print()
@ -452,7 +452,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.salixos_extra_repo_name)
self.delete_bin_database_data(self.repos.salixos_extra_repo_name)
self.delete_last_updated(self.repos.salixos_extra_repo_name)
self.data.install_salixos_extra_data()
print()
@ -482,7 +482,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.salixos_patches_repo_name)
self.delete_bin_database_data(self.repos.salixos_patches_repo_name)
self.delete_last_updated(self.repos.salixos_patches_repo_name)
self.data.install_salixos_patches_data()
print()
@ -509,7 +509,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.slackel_repo_name)
self.delete_bin_database_data(self.repos.slackel_repo_name)
self.delete_last_updated(self.repos.slackel_repo_name)
self.data.install_slackel_data()
print()
@ -536,7 +536,7 @@ class UpdateRepository(Configs):
down.download()
print()
self.delete_binaries_data(self.repos.slint_repo_name)
self.delete_bin_database_data(self.repos.slint_repo_name)
self.delete_last_updated(self.repos.slint_repo_name)
self.data.install_slint_data()
print()
@ -584,7 +584,7 @@ class UpdateRepository(Configs):
self.utils.process(lftp_command)
self.delete_last_updated(self.repos.sbo_repo_name)
self.delete_sbo_data()
self.delete_sbo_database_data()
self.data.install_sbos_data()
def not_enabled_message(self, repo: str) -> None:
@ -639,7 +639,7 @@ class UpdateRepository(Configs):
self.repos_for_update = queue.get()
self.update_the_repositories()
def delete_sbo_data(self) -> None:
def delete_sbo_database_data(self) -> None:
""" Delete all the data from a table of the database. """
if self.repos.ponce_repo:
self.session.query(PonceTable).delete()
@ -647,7 +647,7 @@ class UpdateRepository(Configs):
self.session.query(SBoTable).delete()
self.session.commit()
def delete_binaries_data(self, repo) -> None:
def delete_bin_database_data(self, repo) -> None:
""" Delete the repository data from a table of the database. """
self.session.query(BinariesTable).where(BinariesTable.repo == repo).delete()
self.session.commit()