Change the way to detect build slave.

It seems sys.stdout.isatty() is not a good signal on the build slaves.

TBR=bradnelson
TEST=none
BUG=none

Review URL: http://codereview.chromium.org/3342028

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@59131 0039d316-1c4b-4281-b951-d872f2087c98
experimental/szager/collated-output
maruel@chromium.org 15 years ago
parent e75e8e683c
commit 5f2a196ca6

@ -1176,9 +1176,10 @@ def Main(argv):
for fn in dir(sys.modules[__name__]) if fn.startswith('CMD')])) for fn in dir(sys.modules[__name__]) if fn.startswith('CMD')]))
parser = optparse.OptionParser(version='%prog ' + __version__) parser = optparse.OptionParser(version='%prog ' + __version__)
# TODO(maruel): Temporary workaround to disable parallel checkout on # TODO(maruel): Temporary workaround to disable parallel checkout on
# buildbots until they can correctly parse its output. Uses that fact that # buildbots until they can correctly parse its output. stdout being
# stdout is redirected as a signal. # redirected is not a good signal, at least on linux. Check for environment
if sys.stdout.isatty(): # variable instead.
if 'CHROME_HEADLESS' not in os.environ:
jobs = 8 jobs = 8
else: else:
jobs = 1 jobs = 1

Loading…
Cancel
Save