Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: packagerChrome.py

Issue 29333461: Issue 3516 - Add support for optional permissions (Closed)
Patch Set: Created Jan. 14, 2016, 4:21 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « manifest.json.tmpl ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: packagerChrome.py
diff --git a/packagerChrome.py b/packagerChrome.py
index f26c953a28d52fceb7a030511f52fbb3623aae50..7fdfd45cbe2ad56d9afe8a8947519fcdacc9cff5 100644
--- a/packagerChrome.py
+++ b/packagerChrome.py
@@ -100,6 +100,11 @@ def createManifest(params, files):
if params['experimentalAPI']:
templateData['permissions'].append('experimental')
+ if metadata.has_option('general', 'optionalPermissions'):
+ templateData['optionalPermissions'] = re.split(
Sebastian Noack 2016/01/14 16:26:11 Note that re.split(r'\s+', s) is equivalent to s.s
kzar 2016/01/14 16:39:07 I know, just staying consistent with the surroundi
Sebastian Noack 2016/01/14 16:41:54 Feel free to change it in the other places as well
+ r'\s+', metadata.get('general', 'optionalPermissions')
+ )
+
if metadata.has_option('general', 'backgroundScripts'):
templateData['backgroundScripts'] = re.split(r'\s+', metadata.get('general', 'backgroundScripts'))
if params['devenv']:
« no previous file with comments | « manifest.json.tmpl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld