| OLD | NEW | 
|---|
|  | (Empty) | 
| 1 <?xml version="1.0"?> |  | 
| 2 |  | 
| 3 <!-- This Source Code Form is subject to the terms of the Mozilla Public |  | 
| 4    - License, v. 2.0. If a copy of the MPL was not distributed with this |  | 
| 5    - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> |  | 
| 6 |  | 
| 7 {%- macro meta() -%} |  | 
| 8 <em:creator>{{metadata.get('general', 'author')}}</em:creator> |  | 
| 9 |  | 
| 10 {%- for contributor in contributors -%} |  | 
| 11 <em:contributor>{{contributor}}</em:contributor> |  | 
| 12 {%- endfor -%} |  | 
| 13 {%- endmacro %} |  | 
| 14 |  | 
| 15 <RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#" |  | 
| 16     xmlns:em="http://www.mozilla.org/2004/em-rdf#"> |  | 
| 17 |  | 
| 18   <Description about="urn:mozilla:install-manifest"> |  | 
| 19     <em:id>{{metadata.get('general', 'id')}}</em:id> |  | 
| 20     <em:version>{{version}}</em:version> |  | 
| 21     <em:name>{{localeMetadata[defaultLocale].name}}</em:name> |  | 
| 22     <em:description>{{localeMetadata[defaultLocale].description}}</em:descriptio
     n> |  | 
| 23     {{ meta() }} |  | 
| 24     {%- if metadata.has_option('homepage', 'default') %} |  | 
| 25     <em:homepageURL>{{metadata.get('homepage', 'default')}}</em:homepageURL> |  | 
| 26     {%- endif %} |  | 
| 27     <em:type>2</em:type> |  | 
| 28     <em:bootstrap>true</em:bootstrap> |  | 
| 29     {%- if not metadata.has_option('general', 'needMultiprocessShims') %} |  | 
| 30     <em:multiprocessCompatible>true</em:multiprocessCompatible> |  | 
| 31     {%- endif %} |  | 
| 32     {%- if hasWebExtension %} |  | 
| 33     <em:hasEmbeddedWebExtension>true</em:hasEmbeddedWebExtension> |  | 
| 34     {%- endif %} |  | 
| 35 |  | 
| 36     {%- if metadata.has_option('general', 'updateURL') %} |  | 
| 37     <em:updateURL> |  | 
| 38       {{- metadata.get('general', 'updateURL') -}} |  | 
| 39       {{- '?reqVersion=%REQ_VERSION%&id=%ITEM_ID%&version=%ITEM_VERSION%&maxAppV
     ersion=%ITEM_MAXAPPVERSION%&status=%ITEM_STATUS%&appID=%APP_ID%&appVersion=%APP_
     VERSION%&appOS=%APP_OS%&appABI=%APP_ABI%&locale=%APP_LOCALE%¤tAppVersion=%
     CURRENT_APP_VERSION%&updateType=%UPDATE_TYPE%' -}} |  | 
| 40     </em:updateURL> |  | 
| 41     {%- endif %} |  | 
| 42 |  | 
| 43     {%- if metadata.has_option('general', 'icon') %} |  | 
| 44     <em:iconURL>{{metadata.get('general', 'icon')}}</em:iconURL> |  | 
| 45     {%- endif %} |  | 
| 46 |  | 
| 47     {%- if metadata.has_option('general', 'about') %} |  | 
| 48     <em:aboutURL>{{metadata.get('general', 'about')}}</em:aboutURL> |  | 
| 49     {%- endif %} |  | 
| 50 |  | 
| 51     {%- if metadata.has_option('general', 'options') %} |  | 
| 52     <em:optionsURL>{{metadata.get('general', 'options')}}</em:optionsURL> |  | 
| 53     {%- endif %} |  | 
| 54     {%- if metadata.has_option('general', 'optionsType') %} |  | 
| 55     <em:optionsType>{{metadata.get('general', 'optionsType')}}</em:optionsType> |  | 
| 56     {%- endif %} |  | 
| 57 |  | 
| 58     {%- for localeCode in localeMetadata.keys()|sort %} |  | 
| 59     {%- set locale = localeMetadata[localeCode] %} |  | 
| 60     <em:localized> |  | 
| 61       <Description> |  | 
| 62         <em:locale>{{localeCode}}</em:locale> |  | 
| 63         {{ meta() }} |  | 
| 64         <em:name> |  | 
| 65           {%- if 'name' in locale -%} |  | 
| 66             {{locale.name}} |  | 
| 67           {%- else -%} |  | 
| 68             {{localeMetadata[defaultLocale].name}} |  | 
| 69           {%- endif -%} |  | 
| 70         </em:name> |  | 
| 71         <em:description> |  | 
| 72           {%- if 'description' in locale -%} |  | 
| 73             {{locale.description}} |  | 
| 74           {%- else -%} |  | 
| 75             {{localeMetadata[defaultLocale].description}} |  | 
| 76           {%- endif -%} |  | 
| 77         </em:description> |  | 
| 78         {%- if metadata.has_option('homepage', 'default') %} |  | 
| 79         <em:homepageURL> |  | 
| 80           {%- if metadata.has_option('homepage', localeCode) -%} |  | 
| 81             {{- metadata.get('homepage', localeCode) -}} |  | 
| 82           {%- elif metadata.has_option('homepage', localeCode.split('-')[0]) -%} |  | 
| 83             {{- metadata.get('homepage', localeCode.split('-')[0]) -}} |  | 
| 84           {%- else -%} |  | 
| 85             {{- metadata.get('homepage', 'default') -}} |  | 
| 86           {%- endif -%} |  | 
| 87         </em:homepageURL> |  | 
| 88         {%- endif %} |  | 
| 89         {%- for translator in locale.translators %} |  | 
| 90         <em:translator>{{translator}}</em:translator> |  | 
| 91         {%- endfor %} |  | 
| 92       </Description> |  | 
| 93     </em:localized> |  | 
| 94     {%- endfor %} |  | 
| 95 |  | 
| 96     {%- for appName in metadata.options('compat')|sort %} |  | 
| 97     {%- if appName in KNOWN_APPS %} |  | 
| 98     <em:targetApplication> |  | 
| 99       <Description> |  | 
| 100         <!-- {{appName}} --> |  | 
| 101         <em:id>{{KNOWN_APPS[appName]}}</em:id> |  | 
| 102         <em:minVersion>{{metadata.get('compat', appName).split('/')[0]}}</em:min
     Version> |  | 
| 103         <em:maxVersion>{{metadata.get('compat', appName).split('/')[1]}}</em:max
     Version> |  | 
| 104       </Description> |  | 
| 105     </em:targetApplication> |  | 
| 106     {%- endif %} |  | 
| 107     {%- endfor %} |  | 
| 108   </Description> |  | 
| 109 </RDF> |  | 
| OLD | NEW | 
|---|