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

Side by Side Diff: gclient.py

Issue 8357005: Disable parallel sync on cygwin since it's flaky for users. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 9 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2011 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 """Meta checkout manager supporting both Subversion and GIT. 6 """Meta checkout manager supporting both Subversion and GIT.
7 7
8 Files 8 Files
9 .gclient : Current client configuration, written by 'config' command. 9 .gclient : Current client configuration, written by 'config' command.
10 Format is a Python script defining 'solutions', a list whose 10 Format is a Python script defining 'solutions', a list whose
(...skipping 1414 matching lines...) Expand 10 before | Expand all | Expand 10 after
1425 # OptParser.description prefer nicely non-formatted strings. 1425 # OptParser.description prefer nicely non-formatted strings.
1426 parser.description = re.sub('[\r\n ]{2,}', ' ', obj.__doc__) 1426 parser.description = re.sub('[\r\n ]{2,}', ' ', obj.__doc__)
1427 usage = getattr(obj, 'usage', '') 1427 usage = getattr(obj, 'usage', '')
1428 parser.set_usage('%%prog %s [options] %s' % (command, usage)) 1428 parser.set_usage('%%prog %s [options] %s' % (command, usage))
1429 parser.epilog = getattr(obj, 'epilog', None) 1429 parser.epilog = getattr(obj, 'epilog', None)
1430 1430
1431 1431
1432 def Parser(): 1432 def Parser():
1433 """Returns the default parser.""" 1433 """Returns the default parser."""
1434 parser = optparse.OptionParser(version='%prog ' + __version__) 1434 parser = optparse.OptionParser(version='%prog ' + __version__)
1435 parser.add_option('-j', '--jobs', default=8, type='int', 1435 # cygwin has issues with parallel sync
1436 jobs = 1 if sys.platform == 'cygwin' else 8
1437 parser.add_option('-j', '--jobs', default=jobs, type='int',
1436 help='Specify how many SCM commands can run in parallel; ' 1438 help='Specify how many SCM commands can run in parallel; '
1437 'default=%default') 1439 'default=%default')
1438 parser.add_option('-v', '--verbose', action='count', default=0, 1440 parser.add_option('-v', '--verbose', action='count', default=0,
1439 help='Produces additional output for diagnostics. Can be ' 1441 help='Produces additional output for diagnostics. Can be '
1440 'used up to three times for more logging info.') 1442 'used up to three times for more logging info.')
1441 parser.add_option('--gclientfile', dest='config_filename', 1443 parser.add_option('--gclientfile', dest='config_filename',
1442 default=os.environ.get('GCLIENT_FILE', '.gclient'), 1444 default=os.environ.get('GCLIENT_FILE', '.gclient'),
1443 help='Specify an alternate %default file') 1445 help='Specify an alternate %default file')
1444 # Integrate standard options processing. 1446 # Integrate standard options processing.
1445 old_parser = parser.parse_args 1447 old_parser = parser.parse_args
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
1505 except (gclient_utils.Error, subprocess2.CalledProcessError), e: 1507 except (gclient_utils.Error, subprocess2.CalledProcessError), e:
1506 print >> sys.stderr, 'Error: %s' % str(e) 1508 print >> sys.stderr, 'Error: %s' % str(e)
1507 return 1 1509 return 1
1508 1510
1509 1511
1510 if '__main__' == __name__: 1512 if '__main__' == __name__:
1511 fix_encoding.fix_encoding() 1513 fix_encoding.fix_encoding()
1512 sys.exit(Main(sys.argv[1:])) 1514 sys.exit(Main(sys.argv[1:]))
1513 1515
1514 # vim: ts=2:sw=2:tw=80:et: 1516 # vim: ts=2:sw=2:tw=80:et:
OLDNEW
« 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