mirror of
https://git.yoctoproject.org/poky
synced 2026-06-01 00:59:48 +00:00
bitbake: toaster: whitespace fix
This patch is just a whitespace (end-of-line) fix. (Bitbake rev: 5f33d1a240faa49bd8259a48eb15ef57a6b4ce55) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
9cfa66bd13
commit
d19b784c1a
@@ -142,7 +142,7 @@ def variable_parent_name(value):
|
||||
"""
|
||||
value=re.sub('_\$.*', '', value)
|
||||
return re.sub('_[a-z].*', '', value)
|
||||
|
||||
|
||||
@register.filter
|
||||
def filter_setin_files(file_list,matchstr):
|
||||
""" filter/search the 'set in' file lists. Note
|
||||
@@ -150,7 +150,7 @@ def filter_setin_files(file_list,matchstr):
|
||||
the <p> marks, but this is safe as the data
|
||||
is file paths
|
||||
"""
|
||||
|
||||
|
||||
# no filters, show last file (if any)
|
||||
if matchstr == ":":
|
||||
if file_list:
|
||||
@@ -162,24 +162,24 @@ def filter_setin_files(file_list,matchstr):
|
||||
htmlstr=""
|
||||
# match only filters
|
||||
if search == '':
|
||||
for i in range(len(file_list)):
|
||||
for i in range(len(file_list)):
|
||||
if re.search(filter, file_list[i].file_name):
|
||||
if htmlstr.find(file_list[i].file_name + "<p>") < 0:
|
||||
htmlstr += file_list[i].file_name + "<p>"
|
||||
return htmlstr
|
||||
|
||||
|
||||
# match only search string, plus always last file
|
||||
if filter == "":
|
||||
for i in range(len(file_list)-1):
|
||||
for i in range(len(file_list)-1):
|
||||
if re.search(search,file_list[i].file_name):
|
||||
if htmlstr.find(file_list[i].file_name + "<p>") < 0:
|
||||
htmlstr += file_list[i].file_name + "<p>"
|
||||
if htmlstr.find(file_list[len(file_list)-1].file_name) < 0:
|
||||
htmlstr += file_list[len(file_list)-1].file_name
|
||||
return htmlstr
|
||||
|
||||
|
||||
# match filter or search string
|
||||
for i in range(len(file_list)):
|
||||
for i in range(len(file_list)):
|
||||
if re.search(filter, file_list[i].file_name) or re.search(search,file_list[i].file_name):
|
||||
if htmlstr.find(file_list[i].file_name + "<p>") < 0:
|
||||
htmlstr += file_list[i].file_name + "<p>"
|
||||
@@ -218,7 +218,7 @@ def filtered_packageversion(version, revision):
|
||||
else ""
|
||||
"""
|
||||
return "" if (not version or version == "") else version if (not revision or revision == "") else version + "-" + revision
|
||||
|
||||
|
||||
@register.filter
|
||||
def filter_sizeovertotal(package_object, total_size):
|
||||
""" Return the % size of the package over the total size argument
|
||||
@@ -227,7 +227,7 @@ def filter_sizeovertotal(package_object, total_size):
|
||||
size = package_object.installed_size
|
||||
if size == None or size == '':
|
||||
size = package_object.size
|
||||
|
||||
|
||||
return '{:.1%}'.format(float(size)/float(total_size))
|
||||
|
||||
from django.utils.safestring import mark_safe
|
||||
|
||||
@@ -429,7 +429,7 @@ def builddashboard( request, build_id ):
|
||||
ndx = 0;
|
||||
f = i.file_name[ ndx + 1: ]
|
||||
imageFiles.append({ 'path': f, 'size' : i.file_size })
|
||||
if ( t.is_image and
|
||||
if ( t.is_image and
|
||||
(( len( imageFiles ) <= 0 ) or ( len( t.license_manifest_path ) <= 0 ))):
|
||||
targetHasNoImages = True
|
||||
elem[ 'imageFiles' ] = imageFiles
|
||||
@@ -516,8 +516,8 @@ def task( request, build_id, task_id ):
|
||||
}
|
||||
if request.GET.get( 'show_matches', "" ):
|
||||
context[ 'showing_matches' ] = True
|
||||
context[ 'matching_tasks' ] = Task.objects.filter(
|
||||
sstate_checksum=task.sstate_checksum ).filter(
|
||||
context[ 'matching_tasks' ] = Task.objects.filter(
|
||||
sstate_checksum=task.sstate_checksum ).filter(
|
||||
build__completed_on__lt=task.build.completed_on).exclude(
|
||||
order__isnull=True).exclude(outcome=Task.OUTCOME_NA).order_by('-build__completed_on')
|
||||
|
||||
@@ -551,14 +551,14 @@ def target_common( request, build_id, target_id, variant ):
|
||||
mandatory_parameters = { 'count': 25, 'page' : 1, 'orderby':'name:+'};
|
||||
retval = _verify_parameters( request.GET, mandatory_parameters )
|
||||
if retval:
|
||||
return _redirect_parameters(
|
||||
variant, request.GET, mandatory_parameters,
|
||||
return _redirect_parameters(
|
||||
variant, request.GET, mandatory_parameters,
|
||||
build_id = build_id, target_id = target_id )
|
||||
( filter_string, search_term, ordering_string ) = _search_tuple( request, Package )
|
||||
|
||||
# FUTURE: get rid of nested sub-queries replacing with ManyToMany field
|
||||
queryset = Package.objects.filter(
|
||||
size__gte = 0,
|
||||
size__gte = 0,
|
||||
id__in = Target_Installed_Package.objects.filter(
|
||||
target_id=target_id ).values( 'package_id' ))
|
||||
packages_sum = queryset.aggregate( Sum( 'installed_size' ))
|
||||
@@ -682,7 +682,7 @@ his package',
|
||||
'clclass' : 'layer_directory',
|
||||
'hidden' : 1,
|
||||
}
|
||||
context = {
|
||||
context = {
|
||||
'objectname': variant,
|
||||
'build' : Build.objects.filter( pk = build_id )[ 0 ],
|
||||
'target' : Target.objects.filter( pk = target_id )[ 0 ],
|
||||
|
||||
Reference in New Issue
Block a user