mirror of
https://chromium.googlesource.com/chromium/tools/depot_tools.git
synced 2026-01-11 10:41:31 +00:00
Don't clear directory for new/removed entries
This was from back when we were clearing the whole directory instead of just the extracted contents Bug: b/324418194 Change-Id: I496b0faed2023a8fa3b4ea772a7744f2acc9be6a Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5459298 Reviewed-by: Joanna Wang <jojwang@chromium.org> Commit-Queue: Stephanie Kim <kimstephanie@google.com>
This commit is contained in:
@@ -1987,17 +1987,9 @@ class GcsRoot(object):
|
||||
|
||||
# If any GCS deps are added or removed entirely, clobber that path
|
||||
intersected_paths = parsed_paths.intersection(resolved_paths)
|
||||
# Added paths
|
||||
for path in parsed_paths - intersected_paths:
|
||||
full_path = os.path.join(self.root_dir, path)
|
||||
gclient_utils.rmtree(full_path)
|
||||
# Removed paths
|
||||
for path in resolved_paths - intersected_paths:
|
||||
full_path = os.path.join(self.root_dir, path)
|
||||
gclient_utils.rmtree(full_path)
|
||||
|
||||
# If any objects within a GCS dep are added/removed, clobber that
|
||||
# entire path
|
||||
# If any objects within a GCS dep are added/removed, clobber its
|
||||
# extracted contents and relevant gcs dotfiles
|
||||
for path in intersected_paths:
|
||||
resolved_objects = resolved_object_dict[path]
|
||||
parsed_objects = parsed_object_dict[path]
|
||||
|
||||
Reference in New Issue
Block a user