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

Side by Side Diff: gcl.py

Issue 7925014: Support for |change| argument to |GetPreferredTrySlaves()|. (Closed) Base URL: http://src.chromium.org/svn/trunk/tools/depot_tools/
Patch Set: '' Created 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | presubmit_support.py » ('j') | presubmit_support.py » ('J')
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 """\ 6 """\
7 Wrapper script around Rietveld's upload.py that simplifies working with groups 7 Wrapper script around Rietveld's upload.py that simplifies working with groups
8 of files. 8 of files.
9 """ 9 """
10 10
(...skipping 945 matching lines...) Expand 10 before | Expand all | Expand 10 after
956 trychange_args = [] 956 trychange_args = []
957 if change_info: 957 if change_info:
958 trychange_args.extend(['--name', change_info.name]) 958 trychange_args.extend(['--name', change_info.name])
959 if change_info.issue: 959 if change_info.issue:
960 trychange_args.extend(["--issue", str(change_info.issue)]) 960 trychange_args.extend(["--issue", str(change_info.issue)])
961 if change_info.patchset: 961 if change_info.patchset:
962 trychange_args.extend(["--patchset", str(change_info.patchset)]) 962 trychange_args.extend(["--patchset", str(change_info.patchset)])
963 file_list = change_info.GetFileNames() 963 file_list = change_info.GetFileNames()
964 else: 964 else:
965 file_list = [] 965 file_list = []
966 change = presubmit_support.SvnChange(change_info.name,
967 change_info.description,
968 change_info.GetLocalRoot(),
969 change_info.GetFiles(),
970 change_info.issue,
971 change_info.patchset,
972 None)
966 trychange_args.extend(args) 973 trychange_args.extend(args)
967 return trychange.TryChange( 974 return trychange.TryChange(
968 trychange_args, 975 trychange_args,
976 change=change,
969 file_list=file_list, 977 file_list=file_list,
970 swallow_exception=swallow_exception, 978 swallow_exception=swallow_exception,
971 prog='gcl try', 979 prog='gcl try',
972 extra_epilog='\n' 980 extra_epilog='\n'
973 'When called from gcl, use the format gcl try <change_name>.\n') 981 'When called from gcl, use the format gcl try <change_name>.\n')
974 982
975 983
976 @need_change_and_args 984 @need_change_and_args
977 @attrs(usage='[--no_presubmit]') 985 @attrs(usage='[--no_presubmit]')
978 def CMDcommit(change_info, args): 986 def CMDcommit(change_info, args):
(...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after
1470 raise 1478 raise
1471 print >> sys.stderr, ( 1479 print >> sys.stderr, (
1472 'AppEngine is misbehaving and returned HTTP %d, again. Keep faith ' 1480 'AppEngine is misbehaving and returned HTTP %d, again. Keep faith '
1473 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e)) 1481 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e))
1474 return 1 1482 return 1
1475 1483
1476 1484
1477 if __name__ == "__main__": 1485 if __name__ == "__main__":
1478 fix_encoding.fix_encoding() 1486 fix_encoding.fix_encoding()
1479 sys.exit(main(sys.argv[1:])) 1487 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « no previous file | presubmit_support.py » ('j') | presubmit_support.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698