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

Side by Side Diff: fetch.py

Issue 13532013: add in deltaBaseCacheLimit workaround (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Created 7 years, 8 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
« no previous file with comments | « no previous file | no next file » | 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) 2013 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2013 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 Tool to perform checkouts in one easy command line! 7 Tool to perform checkouts in one easy command line!
8 8
9 Usage: 9 Usage:
10 fetch <recipe> [--property=value [--property2=value2 ...]] 10 fetch <recipe> [--property=value [--property2=value2 ...]]
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 # Ensure we are authenticated with subversion for all submodules. 103 # Ensure we are authenticated with subversion for all submodules.
104 git_svn_dirs = json.loads(self.spec.get('submodule_git_svn_spec', '{}')) 104 git_svn_dirs = json.loads(self.spec.get('submodule_git_svn_spec', '{}'))
105 git_svn_dirs.update({self.root: self.spec}) 105 git_svn_dirs.update({self.root: self.spec})
106 for _, svn_spec in git_svn_dirs.iteritems(): 106 for _, svn_spec in git_svn_dirs.iteritems():
107 try: 107 try:
108 self.run_svn('ls', '--non-interactive', svn_spec['svn_url']) 108 self.run_svn('ls', '--non-interactive', svn_spec['svn_url'])
109 except subprocess.CalledProcessError: 109 except subprocess.CalledProcessError:
110 print 'Please run `svn ls %s`' % svn_spec['svn_url'] 110 print 'Please run `svn ls %s`' % svn_spec['svn_url']
111 return 1 111 return 1
112 112
113 # TODO(dpranke): Work around issues w/ delta compression on big repos.
114 self.run_git('config', '--global', 'core.deltaBaseCacheLimit', '1G')
iannucci 2013/04/04 18:21:30 It would have been cooler to init an empty git rep
115
113 # Configure and do the gclient checkout. 116 # Configure and do the gclient checkout.
114 self.run_gclient('config', '--spec', self.spec['gclient_spec']) 117 self.run_gclient('config', '--spec', self.spec['gclient_spec'])
115 self.run_gclient('sync') 118 self.run_gclient('sync')
116 119
117 # Configure git. 120 # Configure git.
118 wd = os.path.join(self.base, self.root) 121 wd = os.path.join(self.base, self.root)
119 if self.dryrun: 122 if self.dryrun:
120 print 'cd %s' % wd 123 print 'cd %s' % wd
121 self.run_git( 124 self.run_git(
122 'submodule', 'foreach', 125 'submodule', 'foreach',
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 244
242 245
243 def main(): 246 def main():
244 dryrun, recipe, props = handle_args(sys.argv) 247 dryrun, recipe, props = handle_args(sys.argv)
245 spec, root = run_recipe_fetch(recipe, props) 248 spec, root = run_recipe_fetch(recipe, props)
246 return run(dryrun, spec, root) 249 return run(dryrun, spec, root)
247 250
248 251
249 if __name__ == '__main__': 252 if __name__ == '__main__':
250 sys.exit(main()) 253 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698