Fix auto roll update.
authormachenbach@chromium.org <machenbach@chromium.org>
Mon, 3 Nov 2014 15:39:30 +0000 (15:39 +0000)
committermachenbach@chromium.org <machenbach@chromium.org>
Mon, 3 Nov 2014 15:39:43 +0000 (15:39 +0000)
Auto roll requires an additional "git fetch" now that it uses
a workdir. Before, the checkout used to be updated
externally.

BUG=408523
LOG=n
TEST=script_test.py
R=tandrii@chromium.org
TBR=tandrii@chromium.org

Review URL: https://codereview.chromium.org/695323002

Cr-Commit-Position: refs/heads/master@{#25079}
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@25079 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

tools/push-to-trunk/auto_roll.py
tools/push-to-trunk/test_scripts.py

index 00f45e0..1b57097 100755 (executable)
@@ -42,6 +42,7 @@ class DetectLastPush(Step):
   MESSAGE = "Detect commit ID of the last push to trunk."
 
   def RunStep(self):
+    self.vc.Fetch()
     push_hash = self.FindLastTrunkPush(
         branch="origin/candidates", include_patches=True)
     self["last_push"] = self.GetCommitPositionNumber(push_hash)
index 6d1aec5..f31c491 100644 (file)
@@ -1178,6 +1178,8 @@ deps = {
       URL("https://codereview.chromium.org/search",
           "owner=author%40chromium.org&limit=30&closed=3&format=json",
           ("{\"results\": [{\"subject\": \"different\"}]}")),
+      Cmd("git fetch", ""),
+      Cmd("git svn fetch", ""),
       Cmd(("git log -1 --format=%H --grep="
            "\"^Version [[:digit:]]*\.[[:digit:]]*\.[[:digit:]]*\" "
            "origin/candidates"), "push_hash\n"),
@@ -1199,6 +1201,8 @@ deps = {
       URL("https://codereview.chromium.org/search",
           "owner=author%40chromium.org&limit=30&closed=3&format=json",
           ("{\"results\": [{\"subject\": \"different\"}]}")),
+      Cmd("git fetch", ""),
+      Cmd("git svn fetch", ""),
       Cmd(("git log -1 --format=%H --grep="
            "\"^Version [[:digit:]]*\.[[:digit:]]*\.[[:digit:]]*\" "
            "origin/candidates"), "push_hash\n"),