aboutsummaryrefslogtreecommitdiffstats
path: root/python/servo/devenv_commands.py
diff options
context:
space:
mode:
authorMs2ger <Ms2ger@gmail.com>2016-04-15 16:07:49 +0200
committerMs2ger <Ms2ger@gmail.com>2016-04-20 16:06:17 +0200
commit92d8f5c5523b537a1c9f7ff8b2bcfb44c7fb656a (patch)
treef3b33e41ffffdfc249d57ff4fd2f988aa0be09a9 /python/servo/devenv_commands.py
parenteda711307ceb873b32b66a092b7430b8a393059f (diff)
downloadservo-92d8f5c5523b537a1c9f7ff8b2bcfb44c7fb656a.tar.gz
servo-92d8f5c5523b537a1c9f7ff8b2bcfb44c7fb656a.zip
Improve mach wpt-upgrade.
Diffstat (limited to 'python/servo/devenv_commands.py')
-rw-r--r--python/servo/devenv_commands.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/python/servo/devenv_commands.py b/python/servo/devenv_commands.py
index 4ad07477f3f..95bb2d054a9 100644
--- a/python/servo/devenv_commands.py
+++ b/python/servo/devenv_commands.py
@@ -152,11 +152,17 @@ class MachCommands(CommandBase):
code = call(["git", "init"], env=self.build_env())
if code:
return code
- call(
+ code = call(
["git", "remote", "add", "upstream", "https://github.com/w3c/wptrunner.git"], env=self.build_env())
+ if code:
+ return code
code = call(["git", "fetch", "upstream"], env=self.build_env())
if code:
return code
- code = call(["git", "reset", '--', "hard", "remotes/upstream/master"], env=self.build_env())
+ code = call(["git", "reset", "--hard", "remotes/upstream/master"], env=self.build_env())
+ if code:
+ return code
+ code = call(["rm", "-rf", ".git"], env=self.build_env())
if code:
return code
+ return 0