From b7c33ad52301f7e881393d5fee29dd7c9088a372 Mon Sep 17 00:00:00 2001 From: Dimitris Zlatanidis Date: Thu, 16 Mar 2023 22:20:26 +0200 Subject: [PATCH] Updated for error messages --- ChangeLog.txt | 1 + slpkg/main.py | 3 ++- slpkg/update_repository.py | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index e39c46aa..5d7cb0bb 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -2,6 +2,7 @@ Updated: - For empty arguments - Checks for invalid options +- The error messages Added: - Vimdiff in the slpkg_new-configs file (Thanks to tkor) diff --git a/slpkg/main.py b/slpkg/main.py index 17438488..c80d8f96 100644 --- a/slpkg/main.py +++ b/slpkg/main.py @@ -471,7 +471,8 @@ class Argparse(Configs): def clean_tmp(self) -> None: if len(self.args) == 1: - print(f"\n[{self.bred}WARNING{self.endc}]: All the files in the '{self.tmp_path}{self.prog_name}' " + print(f"\n{self.prog_name}: {self.bred}WARNING{self.endc}: All the files in the " + f"'{self.tmp_path}{self.prog_name}' " f"folder will delete!") views = ViewMessage(self.flags) diff --git a/slpkg/update_repository.py b/slpkg/update_repository.py index 291bcdbd..077b5ab0 100644 --- a/slpkg/update_repository.py +++ b/slpkg/update_repository.py @@ -137,7 +137,7 @@ class UpdateRepository(Configs): def drop_the_tables(self): """ Drop all the tables from the database. """ - print(f'[{self.bred}WARNING{self.endc}]: All the data from the database will be deleted!') + print(f'\n{self.prog_name}: {self.bred}WARNING{self.endc}: All the data from the database will be deleted!') self.view.question() tables: list = [PonceTable.__table__,