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

Unified Diff: Source/bindings/scripts/utilities.py

Issue 429853002: IDL: Add build target for IDL dictionary impl generation in core (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 5 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
Index: Source/bindings/scripts/utilities.py
diff --git a/Source/bindings/scripts/utilities.py b/Source/bindings/scripts/utilities.py
index 28beb17c94e8a842c10f7f4ddafa980f47ef0224..74c318a9fbb28332bc572df7657e4debb2830901 100644
--- a/Source/bindings/scripts/utilities.py
+++ b/Source/bindings/scripts/utilities.py
@@ -49,6 +49,9 @@ def write_file(new_text, destination_filename, only_if_changed):
with open(destination_filename) as destination_file:
if destination_file.read() == new_text:
return
+ destination_dirname = os.path.dirname(destination_filename)
+ if not os.path.exists(destination_dirname):
+ os.makedirs(destination_dirname)
with open(destination_filename, 'w') as destination_file:
destination_file.write(new_text)

Powered by Google App Engine
This is Rietveld 408576698