def print_licenses_only(image_obj_list): '''Print a complete list of licenses for all images''' full_license_list = content.get_licenses_only(image_obj_list) # Collect the full list of licenses from all the layers licenses = formats.full_licenses_list.format( list=", ".join(full_license_list) if full_license_list else 'None') return licenses
def write_licenses(image_obj_list): '''Adds licenses to top of the page''' licenses = get_licenses_only(image_obj_list) html_string = '' html_string = html_string + '<ul class ="myUL"> \n' html_string = html_string + '<li><span class="caret">Summary of \ Licenses Found</span> \n' html_string = html_string + '<ul class ="nested"> \n' for lic in licenses: html_string = html_string + \ '<li style="font-family: \'Inconsolata\' , monospace;" >' + \ lic + '</li>\n' html_string = html_string + '</ul></li></ul> \n' return html_string