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

Side by Side Diff: gclient.py

Issue 9255001: Try to unbreak the webkit canary bots. (Closed) Base URL: http://src.chromium.org/svn/trunk/tools/depot_tools/
Patch Set: Created 8 years, 11 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 912 matching lines...) Expand 10 before | Expand all | Expand 10 after
923 self._ApplySafeSyncRev(dep=s) 923 self._ApplySafeSyncRev(dep=s)
924 if not self._options.revisions: 924 if not self._options.revisions:
925 return revision_overrides 925 return revision_overrides
926 solutions_names = [s.name for s in self.dependencies] 926 solutions_names = [s.name for s in self.dependencies]
927 index = 0 927 index = 0
928 for revision in self._options.revisions: 928 for revision in self._options.revisions:
929 if not '@' in revision: 929 if not '@' in revision:
930 # Support for --revision 123 930 # Support for --revision 123
931 revision = '%s@%s' % (solutions_names[index], revision) 931 revision = '%s@%s' % (solutions_names[index], revision)
932 sol, rev = revision.split('@', 1) 932 sol, rev = revision.split('@', 1)
933
934 if not sol in solutions_names and sol == 'trunk':
935 print >> sys.stderr, 'Rewriting "trunk" to "src" in --revision'
936 # Fix attempt for http://crbug.com/108515
937 sol = 'src'
938
933 if not sol in solutions_names: 939 if not sol in solutions_names:
934 #raise gclient_utils.Error('%s is not a valid solution.' % sol) 940 #raise gclient_utils.Error('%s is not a valid solution.' % sol)
935 print >> sys.stderr, ('Please fix your script, having invalid ' 941 print >> sys.stderr, ('Please fix your script, having invalid '
936 '--revision flags will soon considered an error.') 942 '--revision flags will soon considered an error.')
937 else: 943 else:
938 revision_overrides[sol] = rev 944 revision_overrides[sol] = rev
939 index += 1 945 index += 1
940 return revision_overrides 946 return revision_overrides
941 947
942 def _ApplySafeSyncRev(self, dep): 948 def _ApplySafeSyncRev(self, dep):
(...skipping 589 matching lines...) Expand 10 before | Expand all | Expand 10 after
1532 except (gclient_utils.Error, subprocess2.CalledProcessError), e: 1538 except (gclient_utils.Error, subprocess2.CalledProcessError), e:
1533 print >> sys.stderr, 'Error: %s' % str(e) 1539 print >> sys.stderr, 'Error: %s' % str(e)
1534 return 1 1540 return 1
1535 1541
1536 1542
1537 if '__main__' == __name__: 1543 if '__main__' == __name__:
1538 fix_encoding.fix_encoding() 1544 fix_encoding.fix_encoding()
1539 sys.exit(Main(sys.argv[1:])) 1545 sys.exit(Main(sys.argv[1:]))
1540 1546
1541 # vim: ts=2:sw=2:tw=80:et: 1547 # 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