From a8331c7636816cdb3865d1d9bd5e71ad1c98943e Mon Sep 17 00:00:00 2001 From: t0xic0der Date: Jun 03 2020 18:18:50 +0000 Subject: Rewrote RPM Fusion handling view Integrated RPM Fusion checking, server pinging and installing into single module --- diff --git a/MainFunction.py b/MainFunction.py index 8bea026..4b25d10 100644 --- a/MainFunction.py +++ b/MainFunction.py @@ -57,7 +57,25 @@ class InstallationMode(object): pass def rpmadd(self): - pass + DecoratorObject.SectionHeader("CHECKING AVAILABILITY OF RPM FUSION NVIDIA REPOSITORY...") + if RPMFHandler.avbl(): + DecoratorObject.WarningMessage("RPM Fusion repository for Proprietary NVIDIA Driver was detected") + DecoratorObject.SuccessMessage("No further action is necessary") + else: + DecoratorObject.WarningMessage("RPM Fusion repository for Proprietary NVIDIA Driver was not detected") + DecoratorObject.WarningMessage("Repository enabling is required") + DecoratorObject.SectionHeader("ATTEMPTING CONNECTION TO RPM FUSION...") + if RPMFHandler.conn(): + DecoratorObject.SuccessMessage("Connection to RPM Fusion server was estabilished") + DecoratorObject.SectionHeader("INSTALLING RPM FUSION NVIDIA REPOSITORY...") + if RPMFHandler.main(): + DecoratorObject.SuccessMessage("RPM Fusion NVIDIA repository was enabled") + else: + DecoratorObject.FailureMessage("RPM Fusion NVIDIA repository could not be enabled") + else: + DecoratorObject.FailureMessage("RPM Fusion servers could not be connected") + DecoratorObject.FailureMessage("Leaving installer") + sys.exit(0) def driver(self): pass