Deprecate prepare push commit when pushing to trunk.

- This also deprecates using version.cc on bleeding edge.
- The deprecated push-to-trunk.sh is deleted.
- The script now commits bleeding edge HEAD by default. Committing different revisions will be added in a follow up CL.

R=jkummerow@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@20101 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent f7dc76af
...@@ -34,11 +34,11 @@ ...@@ -34,11 +34,11 @@
// system so their names cannot be changed without changing the scripts. // system so their names cannot be changed without changing the scripts.
#define MAJOR_VERSION 3 #define MAJOR_VERSION 3
#define MINOR_VERSION 25 #define MINOR_VERSION 25
#define BUILD_NUMBER 21 #define BUILD_NUMBER 9999
#define PATCH_LEVEL 0 #define PATCH_LEVEL 0
// Use 1 for candidates and 0 otherwise. // Use 1 for candidates and 0 otherwise.
// (Boolean macro values are not supported by all preprocessors.) // (Boolean macro values are not supported by all preprocessors.)
#define IS_CANDIDATE_VERSION 0 #define IS_CANDIDATE_VERSION 1
// Define SONAME to have the build system put a specific SONAME into the // Define SONAME to have the build system put a specific SONAME into the
// shared library instead the generic SONAME generated from the V8 version // shared library instead the generic SONAME generated from the V8 version
......
This diff is collapsed.
...@@ -101,12 +101,10 @@ class DetectLastPush(Step): ...@@ -101,12 +101,10 @@ class DetectLastPush(Step):
self.Die("Could not retrieve bleeding edge git hash for trunk push %s" self.Die("Could not retrieve bleeding edge git hash for trunk push %s"
% last_push) % last_push)
# TODO(machenbach): last_push_trunk points to the svn revision on trunk. # This points to the svn revision of the last push on trunk.
# It is not used yet but we'll need it for retrieving the current version.
self["last_push_trunk"] = last_push self["last_push_trunk"] = last_push
# TODO(machenbach): This currently points to the prepare push revision that # This points to the last bleeding_edge revision that went into the last
# will be deprecated soon. After the deprecation it will point to the last # push.
# bleeding_edge revision that went into the last push.
self["last_push_bleeding_edge"] = last_push_bleeding_edge self["last_push_bleeding_edge"] = last_push_bleeding_edge
...@@ -137,15 +135,6 @@ class IncrementVersion(Step): ...@@ -137,15 +135,6 @@ class IncrementVersion(Step):
self["new_minor"], self["new_minor"],
self["new_build"]) self["new_build"])
# TODO(machenbach): The following will be deprecated. Increment version
# numbers for version.cc on bleeding_edge (new build level on trunk + 1).
text = FileToText(self.Config(VERSION_FILE))
text = MSub(r"(?<=#define BUILD_NUMBER)(?P<space>\s+)\d*$",
r"\g<space>%s" % str(int(self["new_build"]) + 1),
text)
TextToFile(text, self.Config(VERSION_FILE))
self.ReadAndPersistVersion("new_be_")
class PrepareChangeLog(Step): class PrepareChangeLog(Step):
MESSAGE = "Prepare raw ChangeLog entry." MESSAGE = "Prepare raw ChangeLog entry."
...@@ -172,6 +161,7 @@ class PrepareChangeLog(Step): ...@@ -172,6 +161,7 @@ class PrepareChangeLog(Step):
self["date"] = self.GetDate() self["date"] = self.GetDate()
output = "%s: Version %s\n\n" % (self["date"], self["version"]) output = "%s: Version %s\n\n" % (self["date"], self["version"])
TextToFile(output, self.Config(CHANGELOG_ENTRY_FILE)) TextToFile(output, self.Config(CHANGELOG_ENTRY_FILE))
# TODO(machenbach): Retrieve the push hash also from a command-line option.
commits = self.GitLog(format="%H", commits = self.GitLog(format="%H",
git_hash="%s..HEAD" % self["last_push_bleeding_edge"]) git_hash="%s..HEAD" % self["last_push_bleeding_edge"])
...@@ -222,34 +212,6 @@ class EditChangeLog(Step): ...@@ -222,34 +212,6 @@ class EditChangeLog(Step):
TextToFile(changelog_entry, self.Config(CHANGELOG_ENTRY_FILE)) TextToFile(changelog_entry, self.Config(CHANGELOG_ENTRY_FILE))
class CommitLocal(Step):
MESSAGE = "Commit to local branch."
def RunStep(self):
self["prep_commit_msg"] = ("Prepare push to trunk. "
"Now working on version %s.%s.%s." % (self["new_be_major"],
self["new_be_minor"],
self["new_be_build"]))
# Include optional TBR only in the git command. The persisted commit
# message is used for finding the commit again later.
if self._options.tbr_commit:
message = "%s\n\nTBR=%s" % (self["prep_commit_msg"],
self._options.reviewer)
else:
message = "%s" % self["prep_commit_msg"]
self.GitCommit(message)
class CommitRepository(Step):
MESSAGE = "Commit to the repository."
def RunStep(self):
self.WaitForLGTM()
self.GitPresubmit()
self.GitDCommit()
class StragglerCommits(Step): class StragglerCommits(Step):
MESSAGE = ("Fetch straggler commits that sneaked in since this script was " MESSAGE = ("Fetch straggler commits that sneaked in since this script was "
"started.") "started.")
...@@ -257,13 +219,8 @@ class StragglerCommits(Step): ...@@ -257,13 +219,8 @@ class StragglerCommits(Step):
def RunStep(self): def RunStep(self):
self.GitSVNFetch() self.GitSVNFetch()
self.GitCheckout("svn/bleeding_edge") self.GitCheckout("svn/bleeding_edge")
self["prepare_commit_hash"] = self.GitLog(n=1, format="%H", # TODO(machenbach): Retrieve the push hash also from a command-line option.
grep=self["prep_commit_msg"]) self["push_hash"] = self.GitLog(n=1, format="%H", git_hash="HEAD")
# TODO(machenbach): Retrieve the push hash from a command-line option or
# use ToT. The "prepare_commit_hash" will be deprecated along with the
# prepare push commit.
self["push_hash"] = self.GitLog(n=1, format="%H",
parent_hash=self["prepare_commit_hash"])
class SquashCommits(Step): class SquashCommits(Step):
...@@ -364,6 +321,8 @@ class SanityCheck(Step): ...@@ -364,6 +321,8 @@ class SanityCheck(Step):
MESSAGE = "Sanity check." MESSAGE = "Sanity check."
def RunStep(self): def RunStep(self):
# TODO(machenbach): Run presubmit script here as it is now missing in the
# prepare push process.
if not self.Confirm("Please check if your local checkout is sane: Inspect " if not self.Confirm("Please check if your local checkout is sane: Inspect "
"%s, compile, run tests. Do you want to commit this new trunk " "%s, compile, run tests. Do you want to commit this new trunk "
"revision to the repository?" % self.Config(VERSION_FILE)): "revision to the repository?" % self.Config(VERSION_FILE)):
...@@ -542,9 +501,6 @@ class PushToTrunk(ScriptsBase): ...@@ -542,9 +501,6 @@ class PushToTrunk(ScriptsBase):
IncrementVersion, IncrementVersion,
PrepareChangeLog, PrepareChangeLog,
EditChangeLog, EditChangeLog,
CommitLocal,
UploadStep,
CommitRepository,
StragglerCommits, StragglerCommits,
SquashCommits, SquashCommits,
NewBranch, NewBranch,
......
...@@ -709,21 +709,9 @@ Performance and stability improvements on all platforms.""", commit) ...@@ -709,21 +709,9 @@ Performance and stability improvements on all platforms.""", commit)
Git("log -1 --format=%s rev1", "Log text 1.\n"), Git("log -1 --format=%s rev1", "Log text 1.\n"),
Git("log -1 --format=%B rev1", "Text\nLOG=YES\nBUG=v8:321\nText\n"), Git("log -1 --format=%B rev1", "Text\nLOG=YES\nBUG=v8:321\nText\n"),
Git("log -1 --format=%an rev1", "author1@chromium.org\n"), Git("log -1 --format=%an rev1", "author1@chromium.org\n"),
Git(("commit -am \"Prepare push to trunk. "
"Now working on version 3.22.6.%s\"" % review_suffix),
" 2 files changed\n",
cb=CheckPreparePush),
Git(("cl upload --send-mail --email \"author@chromium.org\" "
"-r \"reviewer@chromium.org\"%s" % force_flag),
"done\n"),
Git("cl presubmit", "Presubmit successfull\n"),
Git("cl dcommit -f --bypass-hooks", "Closing issue\n"),
Git("svn fetch", "fetch result\n"), Git("svn fetch", "fetch result\n"),
Git("checkout -f svn/bleeding_edge", ""), Git("checkout -f svn/bleeding_edge", ""),
Git(("log -1 --format=%H --grep=\"Prepare push to trunk. " Git("log -1 --format=%H HEAD", "push_hash\n"),
"Now working on version 3.22.6.\""),
"prep_hash\n"),
Git("log -1 --format=%H prep_hash^", "push_hash\n"),
Git("diff svn/trunk push_hash", "patch content\n"), Git("diff svn/trunk push_hash", "patch content\n"),
Git("svn find-rev push_hash", "123455\n"), Git("svn find-rev push_hash", "123455\n"),
Git("checkout -b %s svn/trunk" % TEST_CONFIG[TRUNKBRANCH], "", Git("checkout -b %s svn/trunk" % TEST_CONFIG[TRUNKBRANCH], "",
...@@ -759,21 +747,12 @@ Performance and stability improvements on all platforms.""", commit) ...@@ -759,21 +747,12 @@ Performance and stability improvements on all platforms.""", commit)
RL("Y"), # Confirm last push. RL("Y"), # Confirm last push.
RL(""), # Open editor. RL(""), # Open editor.
RL("Y"), # Increment build number. RL("Y"), # Increment build number.
RL("reviewer@chromium.org"), # V8 reviewer.
RL("LGTX"), # Enter LGTM for V8 CL (wrong).
RL("LGTM"), # Enter LGTM for V8 CL.
RL("Y"), # Sanity check. RL("Y"), # Sanity check.
RL("reviewer@chromium.org"), # Chromium reviewer. RL("reviewer@chromium.org"), # Chromium reviewer.
]) ])
# Expected keyboard input in semi-automatic mode: # Expected keyboard input in semi-automatic mode and forced mode:
if not manual and not force: if not manual:
self.ExpectReadline([
RL("LGTM"), # Enter LGTM for V8 CL.
])
# No keyboard input in forced mode:
if force:
self.ExpectReadline([]) self.ExpectReadline([])
args = ["-a", "author@chromium.org", "-c", TEST_CONFIG[CHROMIUM]] args = ["-a", "author@chromium.org", "-c", TEST_CONFIG[CHROMIUM]]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment