Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(525)

Unified Diff: components/policy/tools/generate_policy_source.py

Issue 2690563002: Full runtime cloud policy proto will not be generated by default.. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/policy/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/policy/tools/generate_policy_source.py
diff --git a/components/policy/tools/generate_policy_source.py b/components/policy/tools/generate_policy_source.py
index c3544ec3953519ca3e5a54bc87dd8277055684cb..889038aa97b71d57f4005fe85977998c8b133d27 100755
--- a/components/policy/tools/generate_policy_source.py
+++ b/components/policy/tools/generate_policy_source.py
@@ -232,16 +232,23 @@ def main():
writer(sorted and sorted_policy_details or policy_details,
os, f, riskTags)
- GenerateFile(opts.header_path, _WritePolicyConstantHeader, sorted=True)
- GenerateFile(opts.source_path, _WritePolicyConstantSource, sorted=True)
- GenerateFile(opts.risk_header_path, _WritePolicyRiskTagHeader)
- GenerateFile(opts.cloud_policy_proto_path, _WriteCloudPolicyProtobuf)
- GenerateFile(opts.cloud_policy_full_runtime_proto_path,
- _WriteCloudPolicyFullRuntimeProtobuf)
- GenerateFile(opts.chrome_settings_proto_path, _WriteChromeSettingsProtobuf)
- GenerateFile(opts.cloud_policy_decoder_path, _WriteCloudPolicyDecoder)
-
- if os == 'android':
+ if opts.header_path:
+ GenerateFile(opts.header_path, _WritePolicyConstantHeader, sorted=True)
+ if opts.source_path:
+ GenerateFile(opts.source_path, _WritePolicyConstantSource, sorted=True)
+ if opts.risk_header_path:
+ GenerateFile(opts.risk_header_path, _WritePolicyRiskTagHeader)
+ if opts.cloud_policy_proto_path:
+ GenerateFile(opts.cloud_policy_proto_path, _WriteCloudPolicyProtobuf)
+ if opts.cloud_policy_full_runtime_proto_path:
+ GenerateFile(opts.cloud_policy_full_runtime_proto_path,
+ _WriteCloudPolicyFullRuntimeProtobuf)
+ if opts.chrome_settings_proto_path:
+ GenerateFile(opts.chrome_settings_proto_path, _WriteChromeSettingsProtobuf)
+ if opts.cloud_policy_decoder_path:
+ GenerateFile(opts.cloud_policy_decoder_path, _WriteCloudPolicyDecoder)
+
+ if os == 'android' and opts.app_restrictions_path:
GenerateFile(opts.app_restrictions_path, _WriteAppRestrictions, xml=True)
return 0
« no previous file with comments | « components/policy/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698