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

Side by Side Diff: git_cl.py

Issue 7058054: Add --rietveld_XXX arguments to presubmit_support to the commit queue can use it. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 9 years, 6 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 | « gcl.py ('k') | presubmit_support.py » ('j') | 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 # Copyright (C) 2008 Evan Martin <martine@danga.com> 6 # Copyright (C) 2008 Evan Martin <martine@danga.com>
7 7
8 """A git-command for integrating reviews on Rietveld.""" 8 """A git-command for integrating reviews on Rietveld."""
9 9
10 import errno 10 import errno
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after
541 # Apply watchlists on upload. 541 # Apply watchlists on upload.
542 if not committing: 542 if not committing:
543 watchlist = watchlists.Watchlists(change.RepositoryRoot()) 543 watchlist = watchlists.Watchlists(change.RepositoryRoot())
544 files = [f.LocalPath() for f in change.AffectedFiles()] 544 files = [f.LocalPath() for f in change.AffectedFiles()]
545 self.SetWatchers(watchlist.GetWatchersForPaths(files)) 545 self.SetWatchers(watchlist.GetWatchersForPaths(files))
546 546
547 try: 547 try:
548 output = presubmit_support.DoPresubmitChecks(change, committing, 548 output = presubmit_support.DoPresubmitChecks(change, committing,
549 verbose=verbose, output_stream=sys.stdout, input_stream=sys.stdin, 549 verbose=verbose, output_stream=sys.stdout, input_stream=sys.stdin,
550 default_presubmit=None, may_prompt=may_prompt, tbr=tbr, 550 default_presubmit=None, may_prompt=may_prompt, tbr=tbr,
551 rietveld=self.RpcServer()) 551 rietveld_obj=self.RpcServer())
552 except presubmit_support.PresubmitFailure, e: 552 except presubmit_support.PresubmitFailure, e:
553 DieWithError( 553 DieWithError(
554 ('%s\nMaybe your depot_tools is out of date?\n' 554 ('%s\nMaybe your depot_tools is out of date?\n'
555 'If all fails, contact maruel@') % e) 555 'If all fails, contact maruel@') % e)
556 556
557 # TODO(dpranke): We should propagate the error out instead of calling 557 # TODO(dpranke): We should propagate the error out instead of calling
558 # exit(). 558 # exit().
559 if not output.should_continue(): 559 if not output.should_continue():
560 sys.exit(1) 560 sys.exit(1)
561 561
(...skipping 909 matching lines...) Expand 10 before | Expand all | Expand 10 after
1471 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e))) 1471 'and retry or visit go/isgaeup.\n%s') % (e.code, str(e)))
1472 1472
1473 # Not a known command. Default to help. 1473 # Not a known command. Default to help.
1474 GenUsage(parser, 'help') 1474 GenUsage(parser, 'help')
1475 return CMDhelp(parser, argv) 1475 return CMDhelp(parser, argv)
1476 1476
1477 1477
1478 if __name__ == '__main__': 1478 if __name__ == '__main__':
1479 fix_encoding.fix_encoding() 1479 fix_encoding.fix_encoding()
1480 sys.exit(main(sys.argv[1:])) 1480 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « gcl.py ('k') | presubmit_support.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698