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

Unified Diff: gclient_scm.py

Issue 202753003: Rationalize the git config settings for index-pack performance. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: comment Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fetch.py ('k') | gclient_utils.py » ('j') | gclient_utils.py » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gclient_scm.py
diff --git a/gclient_scm.py b/gclient_scm.py
index af48b5f7f33b5984667abe2e4887f9f224e59737..df4c49e8e8a757b0d916b06e6f9a1c6ff184e461 100644
--- a/gclient_scm.py
+++ b/gclient_scm.py
@@ -230,8 +230,8 @@ class GitWrapper(SCMWrapper):
quiet = ['--quiet']
self._UpdateBranchHeads(options, fetch=False)
- fetch_cmd = [
- '-c', 'core.deltaBaseCacheLimit=2g', 'fetch', self.remote, '--prune']
+ cfg = gclient_utils.DefaultIndexPackConfig()
+ fetch_cmd = cfg + ['fetch', self.remote, '--prune']
self._Run(fetch_cmd + quiet, options, retry=True)
self._Run(['reset', '--hard', revision] + quiet, options)
self.UpdateSubmoduleConfig()
@@ -701,8 +701,9 @@ class GitWrapper(SCMWrapper):
print('')
template_path = os.path.join(
os.path.dirname(THIS_FILE_PATH), 'git-templates')
- clone_cmd = ['-c', 'core.deltaBaseCacheLimit=2g', 'clone', '--no-checkout',
- '--progress', '--template=%s' % template_path]
+ cfg = gclient_utils.DefaultIndexPackConfig()
+ clone_cmd = cfg + [
+ 'clone', '--no-checkout', '--progress', '--template=%s' % template_path]
if self.cache_dir:
clone_cmd.append('--shared')
if options.verbose:
@@ -912,7 +913,8 @@ class GitWrapper(SCMWrapper):
'^\\+refs/branch-heads/\\*:.*$']
self._Run(config_cmd, options)
if fetch:
- fetch_cmd = ['-c', 'core.deltaBaseCacheLimit=2g', 'fetch', self.remote]
+ cfg = gclient_utils.DefaultIndexPackConfig()
+ fetch_cmd = cfg + ['fetch', self.remote]
if options.verbose:
fetch_cmd.append('--verbose')
self._Run(fetch_cmd, options, retry=True)
« no previous file with comments | « fetch.py ('k') | gclient_utils.py » ('j') | gclient_utils.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698