| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 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 dependency manager for Git.""" | 6 """Meta checkout dependency manager for Git.""" |
| 7 # Files | 7 # Files |
| 8 # .gclient : Current client configuration, written by 'config' command. | 8 # .gclient : Current client configuration, written by 'config' command. |
| 9 # Format is a Python script defining 'solutions', a list whose | 9 # Format is a Python script defining 'solutions', a list whose |
| 10 # entries each are maps binding the strings "name" and "url" | 10 # entries each are maps binding the strings "name" and "url" |
| (...skipping 1897 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1908 help='GIT ONLY - Forcibly remove repo locks (e.g. ' | 1908 help='GIT ONLY - Forcibly remove repo locks (e.g. ' |
| 1909 'index.lock). This should only be used if you know for ' | 1909 'index.lock). This should only be used if you know for ' |
| 1910 'certain that this invocation of gclient is the only ' | 1910 'certain that this invocation of gclient is the only ' |
| 1911 'thing operating on the git repos (e.g. on a bot).') | 1911 'thing operating on the git repos (e.g. on a bot).') |
| 1912 parser.add_option('--lock_timeout', type='int', default=5000, | 1912 parser.add_option('--lock_timeout', type='int', default=5000, |
| 1913 help='GIT ONLY - Deadline (in seconds) to wait for git ' | 1913 help='GIT ONLY - Deadline (in seconds) to wait for git ' |
| 1914 'cache lock to become available. Default is %default.') | 1914 'cache lock to become available. Default is %default.') |
| 1915 # TODO(agable): Remove these when the oldest CrOS release milestone is M56. | 1915 # TODO(agable): Remove these when the oldest CrOS release milestone is M56. |
| 1916 parser.add_option('-t', '--transitive', action='store_true', | 1916 parser.add_option('-t', '--transitive', action='store_true', |
| 1917 help='DEPRECATED: This is a no-op.') | 1917 help='DEPRECATED: This is a no-op.') |
| 1918 parser.add_option('-m', '--manually_grap_svn_rev', action='store_true', | 1918 parser.add_option('-m', '--manually_grab_svn_rev', action='store_true', |
| 1919 help='DEPRECATED: This is a no-op.') | 1919 help='DEPRECATED: This is a no-op.') |
| 1920 (options, args) = parser.parse_args(args) | 1920 (options, args) = parser.parse_args(args) |
| 1921 client = GClient.LoadCurrentConfig(options) | 1921 client = GClient.LoadCurrentConfig(options) |
| 1922 | 1922 |
| 1923 if not client: | 1923 if not client: |
| 1924 raise gclient_utils.Error('client not configured; see \'gclient config\'') | 1924 raise gclient_utils.Error('client not configured; see \'gclient config\'') |
| 1925 | 1925 |
| 1926 if options.revisions and options.head: | 1926 if options.revisions and options.head: |
| 1927 # TODO(maruel): Make it a parser.error if it doesn't break any builder. | 1927 # TODO(maruel): Make it a parser.error if it doesn't break any builder. |
| 1928 print('Warning: you cannot use both --head and --revision') | 1928 print('Warning: you cannot use both --head and --revision') |
| (...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2180 | 2180 |
| 2181 | 2181 |
| 2182 if '__main__' == __name__: | 2182 if '__main__' == __name__: |
| 2183 try: | 2183 try: |
| 2184 sys.exit(main(sys.argv[1:])) | 2184 sys.exit(main(sys.argv[1:])) |
| 2185 except KeyboardInterrupt: | 2185 except KeyboardInterrupt: |
| 2186 sys.stderr.write('interrupted\n') | 2186 sys.stderr.write('interrupted\n') |
| 2187 sys.exit(1) | 2187 sys.exit(1) |
| 2188 | 2188 |
| 2189 # vim: ts=2:sw=2:tw=80:et: | 2189 # vim: ts=2:sw=2:tw=80:et: |
| OLD | NEW |