diff options
author | Mark Hatle <mark.hatle@windriver.com> | 2018-07-31 18:05:45 -0400 |
---|---|---|
committer | Mark Hatle <mark.hatle@windriver.com> | 2018-08-03 11:46:44 -0400 |
commit | db5d134f397cc92d9c18bc249d914a171ebcc3d9 (patch) | |
tree | 16ab565122bb5f39a78fb96f5c51ef1d61a72488 /lib/bblayers/query.py | |
parent | 8e482342c652e298b5f5ea58eda72c5eb14ce2bd (diff) | |
download | bitbake-contrib-db5d134f397cc92d9c18bc249d914a171ebcc3d9.tar.gz |
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Diffstat (limited to 'lib/bblayers/query.py')
-rw-r--r-- | lib/bblayers/query.py | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/lib/bblayers/query.py b/lib/bblayers/query.py index 9294dfa88..e15fced3c 100644 --- a/lib/bblayers/query.py +++ b/lib/bblayers/query.py @@ -11,6 +11,8 @@ from bblayers.common import LayerPlugin logger = logging.getLogger('bitbake-layers') +import bblayerlib + def plugin_init(plugins): return QueryPlugin() @@ -19,11 +21,16 @@ def plugin_init(plugins): class QueryPlugin(LayerPlugin): def do_show_layers(self, args): """show current configured layers.""" + bblayers = bblayerlib.BBLayers(self.tinfoil.config_data) + + index = bblayers.load_bblayers() + logger.plain("%s %s %s" % ("layer".ljust(20), "path".ljust(40), "priority")) logger.plain('=' * 74) - for layer, _, regex, pri in self.tinfoil.cooker.bbfile_config_priorities: - layerdir = self.bbfile_collections.get(layer, None) - layername = self.get_layer_name(layerdir) + for id, layerbranch in index.layerBranches.items(): + layername = layerbranch.layer.name + layerdir = layerbranch.layer.localpath + pri = layerbranch.layer.priority logger.plain("%s %s %d" % (layername.ljust(20), layerdir.ljust(40), pri)) def version_str(self, pe, pv, pr = None): @@ -119,6 +126,16 @@ skipped recipes will also be listed, with a " (skipped)" suffix. logger.error('No class named %s found in BBPATH', classfile) sys.exit(1) + bblayers = bblayerlib.BBLayers(self.tinfoil.config_data) + index = bblayers.load_bblayers() + index = bblayers.load_recipes(tinfoil=self.tinfoil, full=False) + + for id, recipe in index.recipes.items(): + logger.plain('%s' % (recipe._data)) + + + sys.exit(1) + pkg_pn = self.tinfoil.cooker.recipecaches[''].pkg_pn (latest_versions, preferred_versions) = self.tinfoil.find_providers() allproviders = self.tinfoil.get_all_providers() |