summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/toastergui/views.py
diff options
context:
space:
mode:
authorDave Lerner <dave.lerner@windriver.com>2015-03-11 15:05:08 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-03-25 12:39:51 +0000
commite1a5d8150032b884bd85fcb20de14cd14cfd2b92 (patch)
tree21424e5a3170c1b396d8a8bd8e15ee835a34b710 /bitbake/lib/toaster/toastergui/views.py
parentfa595132b337861898b391229ef54fc5b451a148 (diff)
downloadast2050-yocto-poky-e1a5d8150032b884bd85fcb20de14cd14cfd2b92.zip
ast2050-yocto-poky-e1a5d8150032b884bd85fcb20de14cd14cfd2b92.tar.gz
bitbake: toaster: layer-relative paths for config files
Change bitbake variables table to show the path to the file in which the variable was defined using a layer-relative path instead of the full path to the file. The layer-relative path is found by matching on the full defining file path with entries in a list of layer names, sorted in descending order, and with 'meta' appended as a built-in layer to the end of the list. Additional filters are used to reduce false matches, although even if there is a false match, the actual path to the defining file will be obvious and not misleading. [YOCTO #7414] (Bitbake rev: ef6e854a50ea6894b0e320025280431a6fc8a9a5) Signed-off-by: Dave Lerner <dave.lerner@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/views.py')
-rwxr-xr-xbitbake/lib/toaster/toastergui/views.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/toastergui/views.py b/bitbake/lib/toaster/toastergui/views.py
index ea47d96..9f35062 100755
--- a/bitbake/lib/toaster/toastergui/views.py
+++ b/bitbake/lib/toaster/toastergui/views.py
@@ -1261,6 +1261,11 @@ def configvars(request, build_id):
variables = _build_page_range(Paginator(queryset, pagesize), request.GET.get('page', 1))
+ layers = Layer.objects.filter(layer_version_layer__projectlayer__project__build=build_id).order_by("-name")
+ layer_names = map(lambda layer : layer.name, layers)
+ # special case for meta built-in layer
+ layer_names.append('meta')
+
# show all matching files (not just the last one)
file_filter= search_term + ":"
if filter_string.find('/conf/') > 0:
@@ -1283,6 +1288,7 @@ def configvars(request, build_id):
'total_count':queryset_with_search.count(),
'default_orderby' : 'variable_name:+',
'search_term':search_term,
+ 'layer_names' : layer_names,
# Specifies the display of columns for the table, appearance in "Edit columns" box, toggling default show/hide, and specifying filters for columns
'tablecols' : [
{'name': 'Variable',
OpenPOWER on IntegriCloud