Cleanup .gclient.bot_entries to avoid sync problems on bots.
In https://webrtc-codereview.appspot.com/28509004 the buildbot
case was missed since they get a gclient entries file named
.gclient.bot_entries instead of the regular .gclient_entries
file due to the way the sync was implemented for buildbots.
This change makes the right file get wiped in the two cases.
BUG=
TBR=agable@chromium.org
Review URL: https://webrtc-codereview.appspot.com/28599004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7314 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/sync_chromium.py b/sync_chromium.py
index db6fb98..afcc281 100755
--- a/sync_chromium.py
+++ b/sync_chromium.py
@@ -59,12 +59,6 @@
return 0
os.unlink(flag_file)
- # To avoid gclient sync problems when DEPS entries have been removed we must
- # wipe the .gclient_entries file that contains cached URLs for all DEPS.
- entries_file = os.path.join(opts.chromium_dir, '.gclient_entries')
- if os.path.exists(entries_file):
- os.unlink(entries_file)
-
env = os.environ.copy()
env['GYP_CHROMIUM_NO_ACTION'] = '1'
gclient_cmd = 'gclient.bat' if sys.platform.startswith('win') else 'gclient'
@@ -92,8 +86,16 @@
'--gclientfile', '.gclient.bot',
'--delete_unversioned_trees', '--reset', '--upstream'
]
+ gclient_entries_file = os.path.join(opts.chromium_dir,
+ '.gclient.bot_entries')
else:
args.append('--no-history')
+ gclient_entries_file = os.path.join(opts.chromium_dir, '.gclient_entries')
+
+ # To avoid gclient sync problems when DEPS entries have been removed we must
+ # wipe the gclient's entries file that contains cached URLs for all DEPS.
+ if os.path.exists(gclient_entries_file):
+ os.unlink(gclient_entries_file)
if target_os_list:
args += ['--deps=' + target_os_list]