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

Unified Diff: tools/upload_sdk.py

Issue 8815011: Gets past broken build for --mode debug (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: pretificiation Created 9 years 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/create_sdk.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/upload_sdk.py
diff --git a/tools/upload_sdk.py b/tools/upload_sdk.py
index 049d89fdd5f6182d31918b4330b3bb0cd8921db2..6bad855046b5b3a62b3a5d61dd12e4f7cc8a9fad 100644
--- a/tools/upload_sdk.py
+++ b/tools/upload_sdk.py
@@ -52,20 +52,26 @@ def GetSVNRevision():
return (line.strip().split())[1]
return None
+
+def usage(progname):
+ sys.stderr.write('Usage: %s path_to_sdk\n' % progname)
+
+
def main(argv):
- if (not os.path.exists(argv[1])):
- sys.stderr.write('Usage: upload_sdk.py path_to_sdk\n')
+ if not os.path.exists(argv[1]):
+ sys.stderr.write('Path not found: %s\n' % argv[1])
+ usage(argv[0])
return 1
if (not os.path.exists(GSUTIL)):
exit(0)
revision = GetSVNRevision()
- if revision == None:
+ if revision is None:
sys.stderr.write('Unable to find SVN revision.\n')
return 1
os.chdir(argv[1])
# TODO(dgrove) - deal with architectures that are not ia32.
sdk_name = 'dart-' + utils.GuessOS() + '-' + revision + '.zip'
- sdk_file = '../' + sdk_name
+ sdk_file = '../' + sdk_name
ExecuteCommand(['zip', '-yr', sdk_file, '.'])
UploadArchive(sdk_file, GS_SITE + os.path.join(GS_DIR, SDK, sdk_name))
latest_name = 'dart-' + utils.GuessOS() + '-latest' + '.zip'
« no previous file with comments | « tools/create_sdk.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698