Adds a checkout command to annotated_run.py
To ease the transition into our new adt-infra branch, we will use the
annotated run script to accomplish this for us on our bots. Any bot on
the master ('old') branch will move to the new emu-master-dev branch
once a new build is kicked off.
Change-Id: I3130d97db7d2318091d8656ff8d6958c512df27b
diff --git a/build/scripts/slave/annotated_run.py b/build/scripts/slave/annotated_run.py
index b1ab163..b51b2bb 100755
--- a/build/scripts/slave/annotated_run.py
+++ b/build/scripts/slave/annotated_run.py
@@ -182,8 +182,9 @@
git_cmd = 'git.bat' if os.name == "nt" else 'git'
with stream.step('update_scripts') as s:
fetch_cmd = [git_cmd, 'fetch', '--all']
- reset_cmd = [git_cmd, 'reset', '--hard', 'origin/master']
- if subprocess.call(fetch_cmd) != 0 or subprocess.call(reset_cmd) != 0:
+ reset_cmd = [git_cmd, 'reset', '--hard', 'origin/emu-master-dev']
+ checkout_cmd = [git_cmd, 'checkout', 'emu-master-dev']
+ if subprocess.call(fetch_cmd) != 0 or subprocess.call(reset_cmd) != 0 or subprocess.call(checkout_cmd) != 0:
s.step_text('git update source failed!')
s.step_warnings()
s.step_text('git pull')