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

Unified Diff: dart/tools/bots/bot_utils.py

Issue 24048004: Run gsutil in the cmd.exe shell on windows (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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: dart/tools/bots/bot_utils.py
diff --git a/dart/tools/bots/bot_utils.py b/dart/tools/bots/bot_utils.py
index fc6beefde5b94bd272d5e0beccc3516db6f00b5c..fb29a216ebe3e376fecc71e64deb4f08ab5c8c9c 100644
--- a/dart/tools/bots/bot_utils.py
+++ b/dart/tools/bots/bot_utils.py
@@ -131,10 +131,11 @@ class GCSNamer(object):
return '%s-%s-%s-%s.zip' % (
name, SYSTEM_RENAMES[system], ARCH_RENAMES[arch], mode)
-def run(command, env=None):
+def run(command, env=None, shell=False):
print "Running command: ", command
+
p = subprocess.Popen(command, stdout=subprocess.PIPE,
- stderr=subprocess.PIPE, env=env)
+ stderr=subprocess.PIPE, env=env, shell=shell)
(stdout, stderr) = p.communicate()
if p.returncode != 0:
print >> sys.stderr, "Failed to execute '%s'. Exit code: %s." % (
@@ -184,7 +185,8 @@ class GSUtil(object):
else:
gsutil_command = [sys.executable, GSUtil.GSUTIL_PATH]
- run(gsutil_command + gsutil_args, env=env)
+ run(gsutil_command + gsutil_args, env=env,
+ shell=GSUtil.GSUTIL_IS_SHELL_SCRIPT)
def upload(self, local_path, remote_path, recursive=False, public=False):
assert remote_path.startswith('gs://')
@@ -231,4 +233,3 @@ def CreateChecksumFile(filename, mangled_filename=None):
f.write('%s *%s' % (checksum, mangled_filename))
return checksum_filename
-
« 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