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

Unified Diff: tools/create_debian_packages.py

Issue 208393003: Add default tar file name for source tarball (Closed) Base URL: https://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 | « no previous file | tools/create_tarball.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/create_debian_packages.py
diff --git a/tools/create_debian_packages.py b/tools/create_debian_packages.py
index 4f31dfb21e63b41ad1afeca70f89de4f607196c2..34a86e53abed8e110478c914aba3ff385492c89c 100755
--- a/tools/create_debian_packages.py
+++ b/tools/create_debian_packages.py
@@ -10,11 +10,12 @@
# binary packages.
import optparse
+import platform
import sys
import tarfile
import subprocess
import utils
-
+import os
from os.path import join, exists, abspath
from shutil import copyfile
@@ -30,7 +31,7 @@ def BuildOptions():
result.add_option("--out_dir",
default=None,
help="Where to put the packages.")
-
+
return result
def RunBuildPackage(opt, cwd):
@@ -85,6 +86,7 @@ def BuildDebianPackage(tarball, out_dir):
amd64_package = [
'%s-1_amd64.deb' % debbase
]
+
for name in source_package:
copyfile(join(temp_dir, name), join(out_dir, name))
for name in i386_package:
@@ -102,9 +104,13 @@ def Main():
tar_filename = options.tar_filename
if not options.out_dir:
out_dir = join(DART_DIR, utils.GetBuildDir(HOST_OS, HOST_OS))
- if not options.tar_filename:
- raise Exception('Please specify the input filename.')
- BuildDebianPackage(options.tar_filename, options.out_dir)
+
+ if not tar_filename:
+ tar_filename = join(DART_DIR,
+ utils.GetBuildDir(HOST_OS, HOST_OS),
+ 'dart-%s.tar.gz' % utils.GetVersion())
+
+ BuildDebianPackage(tar_filename, out_dir)
if __name__ == '__main__':
sys.exit(Main())
« no previous file with comments | « no previous file | tools/create_tarball.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698