| OLD | NEW |
| 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 """Access the commit queue from the command line. | 6 """Access the commit queue from the command line. |
| 7 """ | 7 """ |
| 8 | 8 |
| 9 __version__ = '0.1' | 9 __version__ = '0.1' |
| 10 | 10 |
| 11 import functools | 11 import functools |
| 12 import json | 12 import json |
| 13 import logging | 13 import logging |
| 14 import optparse | 14 import optparse |
| 15 import os | 15 import os |
| 16 import sys | 16 import sys |
| 17 import urllib2 | 17 import urllib2 |
| 18 | 18 |
| 19 import breakpad # pylint: disable=W0611 | |
| 20 | |
| 21 import auth | 19 import auth |
| 22 import fix_encoding | 20 import fix_encoding |
| 23 import rietveld | 21 import rietveld |
| 24 | 22 |
| 25 THIRD_PARTY_DIR = os.path.join(os.path.dirname(__file__), 'third_party') | 23 THIRD_PARTY_DIR = os.path.join(os.path.dirname(__file__), 'third_party') |
| 26 sys.path.insert(0, THIRD_PARTY_DIR) | 24 sys.path.insert(0, THIRD_PARTY_DIR) |
| 27 | 25 |
| 28 from cq_client import cq_pb2 | 26 from cq_client import cq_pb2 |
| 29 from protobuf26 import text_format | 27 from protobuf26 import text_format |
| 30 | 28 |
| (...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 294 return CMDhelp(parser, args) | 292 return CMDhelp(parser, args) |
| 295 | 293 |
| 296 | 294 |
| 297 if __name__ == "__main__": | 295 if __name__ == "__main__": |
| 298 fix_encoding.fix_encoding() | 296 fix_encoding.fix_encoding() |
| 299 try: | 297 try: |
| 300 sys.exit(main()) | 298 sys.exit(main()) |
| 301 except KeyboardInterrupt: | 299 except KeyboardInterrupt: |
| 302 sys.stderr.write('interrupted\n') | 300 sys.stderr.write('interrupted\n') |
| 303 sys.exit(1) | 301 sys.exit(1) |
| OLD | NEW |