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

Side by Side Diff: recipe_modules/git/api.py

Issue 2162143004: git: apply a 5 minutes timeout to "ensure git tooling on windows" step (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 | recipe_modules/git/example.expected/platform_win.json » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2013 The Chromium Authors. All rights reserved. 1 # Copyright 2013 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 itertools 5 import itertools
6 import re 6 import re
7 7
8 from recipe_engine import recipe_api 8 from recipe_engine import recipe_api
9 9
10 class GitApi(recipe_api.RecipeApi): 10 class GitApi(recipe_api.RecipeApi):
(...skipping 27 matching lines...) Expand all
38 return f.result 38 return f.result
39 39
40 def ensure_win_git_tooling(self): 40 def ensure_win_git_tooling(self):
41 """Ensures that depot_tools/git.bat actually exists.""" 41 """Ensures that depot_tools/git.bat actually exists."""
42 if not self.m.platform.is_win or self.initialized_win_git: 42 if not self.m.platform.is_win or self.initialized_win_git:
43 return 43 return
44 self.m.step( 44 self.m.step(
45 'ensure git tooling on windows', 45 'ensure git tooling on windows',
46 [self.package_repo_resource('bootstrap', 'win', 'win_tools.bat')], 46 [self.package_repo_resource('bootstrap', 'win', 'win_tools.bat')],
47 infra_step=True, 47 infra_step=True,
48 cwd=self.package_repo_resource()) 48 cwd=self.package_repo_resource(),
49 timeout=300)
49 self.initialized_win_git = True 50 self.initialized_win_git = True
50 51
51 def fetch_tags(self, remote_name=None, **kwargs): 52 def fetch_tags(self, remote_name=None, **kwargs):
52 """Fetches all tags from the remote.""" 53 """Fetches all tags from the remote."""
53 kwargs.setdefault('name', 'git fetch tags') 54 kwargs.setdefault('name', 'git fetch tags')
54 remote_name = remote_name or 'origin' 55 remote_name = remote_name or 'origin'
55 return self('fetch', remote_name, '--tags', **kwargs) 56 return self('fetch', remote_name, '--tags', **kwargs)
56 57
57 def cat_file_at_commit(self, file_path, commit_hash, remote_name=None, 58 def cat_file_at_commit(self, file_path, commit_hash, remote_name=None,
58 **kwargs): 59 **kwargs):
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
368 369
369 Args: 370 Args:
370 bundle_path (Path): The path of the output bundle. 371 bundle_path (Path): The path of the output bundle.
371 refs (list): The list of refs to include in the bundle. If None, all 372 refs (list): The list of refs to include in the bundle. If None, all
372 refs in the Git checkout will be bundled. 373 refs in the Git checkout will be bundled.
373 kwargs: Forwarded to '__call__'. 374 kwargs: Forwarded to '__call__'.
374 """ 375 """
375 if not rev_list_args: 376 if not rev_list_args:
376 rev_list_args = ['--all'] 377 rev_list_args = ['--all']
377 self('bundle', 'create', bundle_path, *rev_list_args, **kwargs) 378 self('bundle', 'create', bundle_path, *rev_list_args, **kwargs)
OLDNEW
« no previous file with comments | « no previous file | recipe_modules/git/example.expected/platform_win.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698