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

Side by Side Diff: recipe_modules/infra_paths/path_config.py

Issue 2102613002: infra_paths: keep cache paths super short to avoid long path issues (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 4 years, 5 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 | Annotate | Revision Log
« 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 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import DEPS 5 import DEPS
6 CONFIG_CTX = DEPS['path'].CONFIG_CTX 6 CONFIG_CTX = DEPS['path'].CONFIG_CTX
7 7
8 8
9 @CONFIG_CTX() 9 @CONFIG_CTX()
10 def infra_common(c): 10 def infra_common(c):
(...skipping 18 matching lines...) Expand all
29 def infra_kitchen(c): 29 def infra_kitchen(c):
30 c.base_paths['root'] = c.CURRENT_WORKING_DIR 30 c.base_paths['root'] = c.CURRENT_WORKING_DIR
31 c.base_paths['slave_build'] = c.CURRENT_WORKING_DIR 31 c.base_paths['slave_build'] = c.CURRENT_WORKING_DIR
32 # TODO(phajdan.jr): have one cache dir, let clients append suffixes. 32 # TODO(phajdan.jr): have one cache dir, let clients append suffixes.
33 33
34 b_dir = c.CURRENT_WORKING_DIR 34 b_dir = c.CURRENT_WORKING_DIR
35 while b_dir and b_dir[-1] != 'b': 35 while b_dir and b_dir[-1] != 'b':
36 b_dir = b_dir[:-1] 36 b_dir = b_dir[:-1]
37 37
38 if c.PLATFORM in ('linux', 'mac'): 38 if c.PLATFORM in ('linux', 'mac'):
39 c.base_paths['cache'] = ( 39 c.base_paths['cache'] = ('/', 'b', 'c')
40 '/', 'b', 'cache', 'chromium') 40 c.base_paths['builder_cache'] = c.base_paths['cache'] + ('b',)
41 for path in ('builder_cache', 'git_cache', 'goma_cache', 'goma_deps_cache'): 41 for path in ('git_cache', 'goma_cache', 'goma_deps_cache'):
42 c.base_paths[path] = c.base_paths['cache'] + (path,) 42 c.base_paths[path] = c.base_paths['cache'] + (path,)
43 elif b_dir: 43 elif b_dir:
44 c.base_paths['cache'] = b_dir + ('cache', 'chromium') 44 c.base_paths['cache'] = b_dir + ('c',)
45 for path in ('builder_cache', 'git_cache', 'goma_cache', 'goma_deps_cache'): 45 c.base_paths['builder_cache'] = c.base_paths['cache'] + ('b',)
46 for path in ('git_cache', 'goma_cache', 'goma_deps_cache'):
46 c.base_paths[path] = c.base_paths['cache'] + (path,) 47 c.base_paths[path] = c.base_paths['cache'] + (path,)
47 else: # pragma: no cover 48 else: # pragma: no cover
48 c.base_paths['cache'] = c.base_paths['root'] + ('cache',) 49 c.base_paths['cache'] = c.base_paths['root'] + ('c',)
50 c.base_paths['builder_cache'] = c.base_paths['cache'] + ('b',)
49 c.base_paths['git_cache'] = c.base_paths['root'] + ('cache_dir',) 51 c.base_paths['git_cache'] = c.base_paths['root'] + ('cache_dir',)
50 for path in ('builder_cache', 'goma_cache', 'goma_deps_cache'): 52 for path in ('goma_cache', 'goma_deps_cache'):
51 c.base_paths[path] = c.base_paths['cache'] + (path,) 53 c.base_paths[path] = c.base_paths['cache'] + (path,)
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