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

Unified Diff: chrome/tools/build/mac/clean_up_old_versions.py

Issue 2184433002: [Mac/GN] In clean_up_old_versions.py, allow the Versions/ directory to not exist. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/tools/build/mac/clean_up_old_versions.py
diff --git a/chrome/tools/build/mac/clean_up_old_versions.py b/chrome/tools/build/mac/clean_up_old_versions.py
index 91ab4bad7a8ebd33a9f8bb29a5c3a7eb088f1e7b..3849112742a13cad7ec1567ff1ce1c8d089ed496 100644
--- a/chrome/tools/build/mac/clean_up_old_versions.py
+++ b/chrome/tools/build/mac/clean_up_old_versions.py
@@ -10,6 +10,9 @@ import sys
def CleanUpOldVersions(path_to_app, keep_version, stamp_path):
versions_dir = os.path.join(path_to_app, 'Contents', 'Versions')
+ if not os.path.exists(versions_dir):
+ return
+
for version in os.listdir(versions_dir):
if version != keep_version:
shutil.rmtree(os.path.join(versions_dir, version))
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698