From 7c2a4882a68a443da2f7bc3990e88e72167c6b8e Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Tue, 2 Jul 2013 22:32:14 +0800 Subject: [PATCH] Make sure the fake config.gypi can be parsed by node.js. --- script/bootstrap.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/script/bootstrap.py b/script/bootstrap.py index 58916467..fa6797bc 100755 --- a/script/bootstrap.py +++ b/script/bootstrap.py @@ -70,10 +70,10 @@ def update_win32_python(): def touch_config_gypi(): config_gypi = os.path.join(SOURCE_ROOT, 'vendor', 'node', 'config.gypi') - if not os.path.exists(config_gypi): - with open(config_gypi, 'w+') as f: - f.truncate(0) - f.write('{}') + with open(config_gypi, 'w+') as f: + content = '\n{}' + if f.read() != content: + f.write(content) def update_atom_shell(): -- 2.43.0