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

Unified Diff: mojo/tools/roll/rev_sdk.py

Issue 790163002: rev_sdk.py: Don't "git rm" nonexistent directories in Chromium. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 6 years 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: mojo/tools/roll/rev_sdk.py
diff --git a/mojo/tools/roll/rev_sdk.py b/mojo/tools/roll/rev_sdk.py
index 1fe7095ab5ad3679a607a370d291f4dcf0f92ba5..a0cd5d9540a191546d4d688374b8b26c89397c98 100755
--- a/mojo/tools/roll/rev_sdk.py
+++ b/mojo/tools/roll/rev_sdk.py
@@ -22,8 +22,9 @@ def rev(source_dir, chromium_dir):
src_commit = system(["git", "show-ref", "HEAD", "-s"], cwd=source_dir).strip()
for d in dirs_to_clone:
- print "removing directory %s" % d
- system(["git", "rm", "-r", d], cwd=chromium_dir)
+ if os.path.exists(os.path.join(chromium_dir, d)):
+ print "removing directory %s" % d
+ system(["git", "rm", "-r", d], cwd=chromium_dir)
print "cloning directory %s" % d
files = system(["git", "ls-files", d], cwd=source_dir)
for f in files.splitlines():
« 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