Index: packagerChrome.py |
diff --git a/packagerChrome.py b/packagerChrome.py |
index 6f09e9ccf95e7a7903097cbd31c642d63018886e..49b9b18e4d0beaf8612ff85184ea8310d986dfa6 100644 |
--- a/packagerChrome.py |
+++ b/packagerChrome.py |
@@ -13,6 +13,7 @@ import subprocess |
import sys |
import random |
import posixpath |
+import ConfigParser |
from packager import (readMetadata, getDefaultFileName, getBuildVersion, |
getTemplate, get_extension, Files, get_app_id) |
@@ -122,6 +123,27 @@ def createManifest(params, files): |
templateData['webAccessible'] = metadata.get('general', |
'webAccessible').split() |
+ for key in ['externallyConnectable_matches', 'externallyConnectable_ids']: |
+ try: |
+ values = metadata.get('general', key) |
+ if values == '': |
+ continue |
+ |
+ sub_key = key.split('_', 1)[1] |
+ templateData.setdefault('externallyConnectable', {}) |
+ templateData['externallyConnectable'][sub_key] = values.split() |
+ except ConfigParser.NoOptionError: |
+ continue |
+ |
+ # We don't need to configure accept_ts_channel_id if nothing can connect |
+ if 'externallyConnectable' in templateData.keys(): |
+ try: |
+ key = 'accepts_tls_channel_id' |
+ val = metadata.get('general', 'externallyConnectable_' + key) |
+ templateData['externallyConnectable'][key] = val == 'true' |
+ except ConfigParser.NoOptionError: |
+ pass |
+ |
if metadata.has_section('contentScripts'): |
contentScripts = [] |
for run_at, scripts in metadata.items('contentScripts'): |