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

Unified Diff: tools/bots/src-tarball.py

Issue 197313010: Initial refactorings to support archiving the src and debian package builds. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 9 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 | « tools/bots/bot_utils.py ('k') | tools/create_debian_packages.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/bots/src-tarball.py
===================================================================
--- tools/bots/src-tarball.py (revision 33696)
+++ tools/bots/src-tarball.py (working copy)
@@ -11,11 +11,16 @@
Archive tarball and debian package to google cloud storage.
"""
+import os
import re
import sys
import bot
+import bot_utils
+utils = bot_utils.GetUtils()
+
+HOST_OS = utils.GuessOS()
SRC_BUILDER = r'src-tarball-linux'
def SrcConfig(name, is_buildbot):
@@ -32,12 +37,26 @@
return bot.BuildInfo('none', 'none', 'release', 'linux')
def SrcSteps(build_info):
+ # We always clobber the bot, to not leave old tarballs and packages
+ # floating around the out dir.
+ bot.Clobber(force=True)
with bot.BuildStep('Create src tarball'):
- args = [sys.executable, './tools/create_tarball.py']
+ version = utils.GetVersion()
+ builddir = os.path.join(bot_utils.DART_DIR,
+ utils.GetBuildDir(HOST_OS, HOST_OS),
+ 'src_and_installation')
+ if not os.path.exists(builddir):
+ os.makedirs(builddir)
+ tarfilename = 'dart-%s.tar.gz' % version
+ tarfile = os.path.join(builddir, tarfilename)
+ args = [sys.executable, './tools/create_tarball.py', '--tar_filename',
+ tarfile]
print 'Building src tarball'
bot.RunProcess(args)
print 'Building Debian packages'
- args = [sys.executable, './tools/create_debian_packages.py']
+ args = [sys.executable, './tools/create_debian_packages.py',
+ '--tar_filename', tarfile,
+ '--out_dir', builddir]
bot.RunProcess(args)
if __name__ == '__main__':
« no previous file with comments | « tools/bots/bot_utils.py ('k') | tools/create_debian_packages.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698