[gnome-continuous-yocto/gnomeostree-3.28-rocko: 4917/8267] wic: remove PluginMgr.get_source_plugins



commit 27e172c3b63d002ef4376b29d0cb5e461ced3e58
Author: Ed Bartosh <ed bartosh linux intel com>
Date:   Wed Feb 15 14:24:17 2017 +0200

    wic: remove PluginMgr.get_source_plugins
    
    Used get_plugins('source') instead of get_source_plugins to
    unify and simplify API to get plugins.
    
    (From OE-Core rev: aaab003e472416124d7342fc8c4a17c252b83f4d)
    
    Signed-off-by: Ed Bartosh <ed bartosh linux intel com>
    Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>

 scripts/lib/wic/engine.py    |    2 +-
 scripts/lib/wic/partition.py |    2 +-
 scripts/lib/wic/plugin.py    |   12 ------------
 3 files changed, 2 insertions(+), 14 deletions(-)
---
diff --git a/scripts/lib/wic/engine.py b/scripts/lib/wic/engine.py
index 98e7b95..4d0901d 100644
--- a/scripts/lib/wic/engine.py
+++ b/scripts/lib/wic/engine.py
@@ -139,7 +139,7 @@ def list_source_plugins():
     """
     List the available source plugins i.e. plugins available for --source.
     """
-    plugins = PluginMgr.get_source_plugins()
+    plugins = PluginMgr.get_plugins('source')
 
     for plugin in plugins:
         print("  %s" % plugin)
diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index f8d4274..d3cd593 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -154,7 +154,7 @@ class Partition():
                         break
             return
 
-        plugins = PluginMgr.get_source_plugins()
+        plugins = PluginMgr.get_plugins('source')
 
         if self.source not in plugins:
             raise WicError("The '%s' --source specified for %s doesn't exist.\n\t"
diff --git a/scripts/lib/wic/plugin.py b/scripts/lib/wic/plugin.py
index 7632c3a..064243d 100644
--- a/scripts/lib/wic/plugin.py
+++ b/scripts/lib/wic/plugin.py
@@ -109,18 +109,6 @@ class PluginMgr:
         return pluginbase.get_plugins(ptype)
 
     @classmethod
-    def get_source_plugins(cls):
-        """
-        Return list of available source plugins.
-        """
-        plugins_dir = cls._build_plugin_dir_list(cls.plugin_dir, 'source')
-
-        cls.append_dirs(plugins_dir)
-
-        return cls.get_plugins('source')
-
-
-    @classmethod
     def get_source_plugin_methods(cls, source_name, methods):
         """
         The methods param is a dict with the method names to find.  On


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]