Chromium Code Reviews| Index: recipe_modules/git/api.py |
| diff --git a/recipe_modules/git/api.py b/recipe_modules/git/api.py |
| index 00524b9622ce700cb871d6e221cbc411318124f4..c2d4eb06ddf117c3854acdd969c2876561ae6d4a 100644 |
| --- a/recipe_modules/git/api.py |
| +++ b/recipe_modules/git/api.py |
| @@ -208,11 +208,16 @@ class GitApi(recipe_api.RecipeApi): |
| self.resource('git_setup.py'), |
| git_setup_args) |
| + # Some of the commands below require depot_tools to be in PATH. |
| + path = self.m.path.pathsep.join([ |
| + str(self.package_repo_resource()), '%(PATH)s']) |
|
nodir
2016/07/29 17:41:50
does %(PATH)s work? I don't know what expands it
borenet
2016/07/29 18:56:01
Yeah, must be the recipe engine. We use it in a c
|
| + |
| if use_git_cache: |
| self('retry', 'cache', 'fetch', '-c', self.m.path['git_cache'], |
| cwd=dir_path, |
| name='fetch cache', |
| - can_fail_build=can_fail_build) |
| + can_fail_build=can_fail_build, |
| + env={'PATH': path}) |
| # There are five kinds of refs we can be handed: |
| # 0) None. In this case, we default to properties['branch']. |
| @@ -246,7 +251,7 @@ class GitApi(recipe_api.RecipeApi): |
| if recursive: |
| fetch_args.append('--recurse-submodules') |
| - fetch_env = {} |
| + fetch_env = {'PATH': path} |
| fetch_stderr = None |
| if curl_trace_file: |
| fetch_env['GIT_CURL_VERBOSE'] = '1' |