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 manager supporting both Subversion and GIT.""" | 6 """Meta checkout manager supporting both Subversion and 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 1790 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1801 'platform(s); \'all\' will process all deps_os ' | 1801 'platform(s); \'all\' will process all deps_os ' |
1802 'references') | 1802 'references') |
1803 parser.add_option('-m', '--manually_grab_svn_rev', action='store_true', | 1803 parser.add_option('-m', '--manually_grab_svn_rev', action='store_true', |
1804 help='Skip svn up whenever possible by requesting ' | 1804 help='Skip svn up whenever possible by requesting ' |
1805 'actual HEAD revision from the repository') | 1805 'actual HEAD revision from the repository') |
1806 parser.add_option('--upstream', action='store_true', | 1806 parser.add_option('--upstream', action='store_true', |
1807 help='Make repo state match upstream branch.') | 1807 help='Make repo state match upstream branch.') |
1808 parser.add_option('--output-json', | 1808 parser.add_option('--output-json', |
1809 help='Output a json document to this path containing ' | 1809 help='Output a json document to this path containing ' |
1810 'summary information about the sync.') | 1810 'summary information about the sync.') |
| 1811 parser.add_option('--no-history', action='store_true', |
| 1812 help='GIT ONLY - Reduces the size/time of the checkout at ' |
| 1813 'the cost of no history. Requires Git 1.9+') |
1811 parser.add_option('--shallow', action='store_true', | 1814 parser.add_option('--shallow', action='store_true', |
1812 help='GIT ONLY - Do a shallow clone into the cache dir. ' | 1815 help='GIT ONLY - Do a shallow clone into the cache dir. ' |
1813 'Requires Git 1.9+') | 1816 'Requires Git 1.9+') |
1814 parser.add_option('--ignore_locks', action='store_true', | 1817 parser.add_option('--ignore_locks', action='store_true', |
1815 help='GIT ONLY - Ignore cache locks.') | 1818 help='GIT ONLY - Ignore cache locks.') |
1816 (options, args) = parser.parse_args(args) | 1819 (options, args) = parser.parse_args(args) |
1817 client = GClient.LoadCurrentConfig(options) | 1820 client = GClient.LoadCurrentConfig(options) |
1818 | 1821 |
1819 if not client: | 1822 if not client: |
1820 raise gclient_utils.Error('client not configured; see \'gclient config\'') | 1823 raise gclient_utils.Error('client not configured; see \'gclient config\'') |
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2057 print >> sys.stderr, 'Error: %s' % str(e) | 2060 print >> sys.stderr, 'Error: %s' % str(e) |
2058 return 1 | 2061 return 1 |
2059 finally: | 2062 finally: |
2060 gclient_utils.PrintWarnings() | 2063 gclient_utils.PrintWarnings() |
2061 | 2064 |
2062 | 2065 |
2063 if '__main__' == __name__: | 2066 if '__main__' == __name__: |
2064 sys.exit(Main(sys.argv[1:])) | 2067 sys.exit(Main(sys.argv[1:])) |
2065 | 2068 |
2066 # vim: ts=2:sw=2:tw=80:et: | 2069 # vim: ts=2:sw=2:tw=80:et: |
OLD | NEW |