Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(67)

Unified Diff: tools/safely-roll-webkit.py

Issue 10532110: Show old revision number in WebKit rolls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/safely-roll-webkit.py
diff --git a/tools/safely-roll-webkit.py b/tools/safely-roll-webkit.py
index 2ddb08687443f41babd5864bc3df7ef36d312b45..d58fb6674beebaa2027ce545ecbda28a4132f662 100755
--- a/tools/safely-roll-webkit.py
+++ b/tools/safely-roll-webkit.py
@@ -35,7 +35,10 @@ def process_deps(path, new_rev):
new_content = re.sub(old_line, new_line, content, 1)
if new_content == content:
die_with_error('Failed to update the DEPS file')
+
+ old_rev = re.search(old_line, content)
M-A Ruel 2012/06/12 22:01:29 what about moving this just before line 35 and "as
open(path, 'w').write(new_content)
+ return old_rev.group(2)
def main():
@@ -54,8 +57,7 @@ def main():
os.chdir(root_dir)
new_rev = int(args[0])
- msg = 'Roll webkit revision to %s' % new_rev
- print msg
+ print 'Roll webkit revision to %s' % new_rev
# Silence the editor.
os.environ['EDITOR'] = 'true'
@@ -67,8 +69,8 @@ def main():
subprocess2.check_output(
['git', 'checkout', '-b', 'webkit_roll', 'origin/master'])
try:
- process_deps(os.path.join(root_dir, 'DEPS'), new_rev)
- commit_msg = msg + '\n\nTBR=\n'
+ old_rev = process_deps(os.path.join(root_dir, 'DEPS'), new_rev)
+ commit_msg = 'Webkit roll %s:%s\n\nTBR=\n' % (old_rev, new_rev)
subprocess2.check_output(['git', 'commit', '-m', commit_msg, 'DEPS'])
subprocess2.check_call(['git', 'diff', 'origin/master'])
subprocess2.check_call(['git', 'cl', 'upload', '--use-commit-queue'])
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698