| Index: tools/push-to-trunk/push_to_trunk.py
|
| diff --git a/tools/push-to-trunk/push_to_trunk.py b/tools/push-to-trunk/push_to_trunk.py
|
| index 6fcc90140ccdbd50f46ebd9b674ae3a7f91e6ea4..b487b0f8fafab1bde6d5b1663571de558edc68d4 100755
|
| --- a/tools/push-to-trunk/push_to_trunk.py
|
| +++ b/tools/push-to-trunk/push_to_trunk.py
|
| @@ -34,8 +34,6 @@ import urllib2
|
| from common_includes import *
|
|
|
| TRUNKBRANCH = "TRUNKBRANCH"
|
| -CHROMIUM = "CHROMIUM"
|
| -DEPS_FILE = "DEPS_FILE"
|
|
|
| CONFIG = {
|
| BRANCHNAME: "prepare-push",
|
| @@ -48,7 +46,6 @@ CONFIG = {
|
| CHANGELOG_ENTRY_FILE: "/tmp/v8-push-to-trunk-tempfile-changelog-entry",
|
| PATCH_FILE: "/tmp/v8-push-to-trunk-tempfile-patch-file",
|
| COMMITMSG_FILE: "/tmp/v8-push-to-trunk-tempfile-commitmsg",
|
| - DEPS_FILE: "DEPS",
|
| }
|
|
|
| PUSH_MESSAGE_SUFFIX = " (based on bleeding_edge revision r%d)"
|
| @@ -373,100 +370,15 @@ class TagRevision(Step):
|
| self.GitSVNTag(self["version"])
|
|
|
|
|
| -class CheckChromium(Step):
|
| - MESSAGE = "Ask for chromium checkout."
|
| -
|
| - def Run(self):
|
| - self["chrome_path"] = self._options.chromium
|
| - if not self["chrome_path"]:
|
| - self.DieNoManualMode("Please specify the path to a Chromium checkout in "
|
| - "forced mode.")
|
| - print ("Do you have a \"NewGit\" Chromium checkout and want "
|
| - "this script to automate creation of the roll CL? If yes, enter the "
|
| - "path to (and including) the \"src\" directory here, otherwise just "
|
| - "press <Return>: "),
|
| - self["chrome_path"] = self.ReadLine()
|
| -
|
| -
|
| -class SwitchChromium(Step):
|
| - MESSAGE = "Switch to Chromium checkout."
|
| - REQUIRES = "chrome_path"
|
| -
|
| - def RunStep(self):
|
| - self["v8_path"] = os.getcwd()
|
| - os.chdir(self["chrome_path"])
|
| - self.InitialEnvironmentChecks()
|
| - # Check for a clean workdir.
|
| - if not self.GitIsWorkdirClean(): # pragma: no cover
|
| - self.Die("Workspace is not clean. Please commit or undo your changes.")
|
| - # Assert that the DEPS file is there.
|
| - if not os.path.exists(self.Config(DEPS_FILE)): # pragma: no cover
|
| - self.Die("DEPS file not present.")
|
| -
|
| -
|
| -class UpdateChromiumCheckout(Step):
|
| - MESSAGE = "Update the checkout and create a new branch."
|
| - REQUIRES = "chrome_path"
|
| -
|
| - def RunStep(self):
|
| - os.chdir(self["chrome_path"])
|
| - self.GitCheckout("master")
|
| - self.GitPull()
|
| - self.GitCreateBranch("v8-roll-%s" % self["trunk_revision"])
|
| -
|
| -
|
| -class UploadCL(Step):
|
| - MESSAGE = "Create and upload CL."
|
| - REQUIRES = "chrome_path"
|
| -
|
| - def RunStep(self):
|
| - os.chdir(self["chrome_path"])
|
| -
|
| - # Patch DEPS file.
|
| - deps = FileToText(self.Config(DEPS_FILE))
|
| - deps = re.sub("(?<=\"v8_revision\": \")([0-9]+)(?=\")",
|
| - self["trunk_revision"],
|
| - deps)
|
| - TextToFile(deps, self.Config(DEPS_FILE))
|
| -
|
| - if self._options.reviewer:
|
| - print "Using account %s for review." % self._options.reviewer
|
| - rev = self._options.reviewer
|
| - else:
|
| - print "Please enter the email address of a reviewer for the roll CL: ",
|
| - self.DieNoManualMode("A reviewer must be specified in forced mode.")
|
| - rev = self.ReadLine()
|
| - suffix = PUSH_MESSAGE_SUFFIX % int(self["svn_revision"])
|
| - self.GitCommit("Update V8 to version %s%s.\n\nTBR=%s"
|
| - % (self["version"], suffix, rev))
|
| - self.GitUpload(author=self._options.author,
|
| - force=self._options.force_upload)
|
| - print "CL uploaded."
|
| -
|
| -
|
| -class SwitchV8(Step):
|
| - MESSAGE = "Returning to V8 checkout."
|
| - REQUIRES = "chrome_path"
|
| -
|
| - def RunStep(self):
|
| - os.chdir(self["v8_path"])
|
| -
|
| -
|
| class CleanUp(Step):
|
| MESSAGE = "Done!"
|
|
|
| def RunStep(self):
|
| - if self["chrome_path"]:
|
| - print("Congratulations, you have successfully created the trunk "
|
| - "revision %s and rolled it into Chromium. Please don't forget to "
|
| - "update the v8rel spreadsheet:" % self["version"])
|
| - else: # pragma: no cover
|
| - print("Congratulations, you have successfully created the trunk "
|
| - "revision %s. Please don't forget to roll this new version into "
|
| - "Chromium, and to update the v8rel spreadsheet:"
|
| - % self["version"])
|
| - print "%s\ttrunk\t%s" % (self["version"],
|
| - self["trunk_revision"])
|
| + print("Congratulations, you have successfully created the trunk "
|
| + "revision %s. Please don't forget to roll this new version into "
|
| + "Chromium, and to update the v8rel spreadsheet:"
|
| + % self["version"])
|
| + print "%s\ttrunk\t%s" % (self["version"], self["trunk_revision"])
|
|
|
| self.CommonCleanup()
|
| if self.Config(TRUNKBRANCH) != self["current_branch"]:
|
| @@ -486,9 +398,6 @@ class PushToTrunk(ScriptsBase):
|
| help=("The git commit ID of the last bleeding edge "
|
| "revision that was pushed to trunk. This is "
|
| "used for the auto-generated ChangeLog entry."))
|
| - parser.add_argument("-c", "--chromium",
|
| - help=("The path to your Chromium src/ "
|
| - "directory to automate the V8 roll."))
|
| parser.add_argument("-l", "--last-push",
|
| help="The git commit ID of the last push to trunk.")
|
| parser.add_argument("-R", "--revision",
|
| @@ -498,9 +407,6 @@ class PushToTrunk(ScriptsBase):
|
| if not options.manual and not options.reviewer:
|
| print "A reviewer (-r) is required in (semi-)automatic mode."
|
| return False
|
| - if not options.manual and not options.chromium:
|
| - print "A chromium checkout (-c) is required in (semi-)automatic mode."
|
| - return False
|
| if not options.manual and not options.author:
|
| print "Specify your chromium.org email with -a in (semi-)automatic mode."
|
| return False
|
| @@ -531,11 +437,6 @@ class PushToTrunk(ScriptsBase):
|
| SanityCheck,
|
| CommitSVN,
|
| TagRevision,
|
| - CheckChromium,
|
| - SwitchChromium,
|
| - UpdateChromiumCheckout,
|
| - UploadCL,
|
| - SwitchV8,
|
| CleanUp,
|
| ]
|
|
|
|
|