mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2024-11-17 07:48:18 +01:00
Updated for doubles deps
This commit is contained in:
parent
5d74ed0403
commit
eae94cdcc4
1 changed files with 11 additions and 1 deletions
|
@ -34,6 +34,7 @@ class RemovePackages(Configs):
|
|||
self.logs_dependencies: dict = {}
|
||||
self.process_message: str = str()
|
||||
self.installed_packages: list = []
|
||||
self.installed_dependencies: list = []
|
||||
self.dependencies: list = []
|
||||
self.stderr = None
|
||||
self.stdout = None
|
||||
|
@ -50,6 +51,8 @@ class RemovePackages(Configs):
|
|||
def remove(self) -> None:
|
||||
self.query_logs_dependencies()
|
||||
self.save_dependencies_for_remove()
|
||||
self.remove_doubles_dependencies()
|
||||
self.add_dependencies_to_remove()
|
||||
self.choose_dependencies_for_remove()
|
||||
self.save_packages_for_remove()
|
||||
|
||||
|
@ -71,7 +74,14 @@ class RemovePackages(Configs):
|
|||
installed: str = self.utils.is_package_installed(require)
|
||||
if installed and require not in self.packages:
|
||||
self.dependencies.append(require)
|
||||
self.installed_packages.append(installed)
|
||||
self.installed_dependencies.append(installed)
|
||||
|
||||
def remove_doubles_dependencies(self):
|
||||
self.dependencies: list = list(set(self.dependencies))
|
||||
self.installed_dependencies: list = list(set(self.installed_dependencies))
|
||||
|
||||
def add_dependencies_to_remove(self):
|
||||
self.installed_packages.extend(self.installed_dependencies)
|
||||
|
||||
def save_packages_for_remove(self):
|
||||
for package in self.packages:
|
||||
|
|
Loading…
Reference in a new issue