@ -432,13 +432,13 @@ Returns:
[DEPS ](/recipes/recipe_modules/git/__init__.py#3 ): [depot\_tools ](#recipe_modules-depot_tools ), [recipe\_engine/buildbucket][recipe_engine/recipe_modules/buildbucket], [recipe\_engine/context][recipe_engine/recipe_modules/context], [recipe\_engine/path][recipe_engine/recipe_modules/path], [recipe\_engine/platform][recipe_engine/recipe_modules/platform], [recipe\_engine/properties][recipe_engine/recipe_modules/properties], [recipe\_engine/raw\_io][recipe_engine/recipe_modules/raw_io], [recipe\_engine/runtime][recipe_engine/recipe_modules/runtime], [recipe\_engine/step][recipe_engine/recipe_modules/step]
#### **class [GitApi ](/recipes/recipe_modules/git/api.py#1 1 )([RecipeApi][recipe_engine/wkt/RecipeApi]):**
#### **class [GitApi ](/recipes/recipe_modules/git/api.py#1 0 )([RecipeApi][recipe_engine/wkt/RecipeApi]):**
— **def [\_\_call\_\_ ](/recipes/recipe_modules/git/api.py#1 4 )(self, \*args, \*\*kwargs):**
— **def [\_\_call\_\_ ](/recipes/recipe_modules/git/api.py#1 3 )(self, \*args, \*\*kwargs):**
Returns a git command step.
— **def [bundle\_create ](/recipes/recipe_modules/git/api.py#39 1 )(self, bundle_path, rev_list_args=None, \*\*kwargs):**
— **def [bundle\_create ](/recipes/recipe_modules/git/api.py#39 0 )(self, bundle_path, rev_list_args=None, \*\*kwargs):**
Runs 'git bundle create' on a Git repository.
@ -448,11 +448,11 @@ Args:
refs in the Git checkout will be bundled.
* kwargs: Forwarded to '__call__'.
— **def [cat\_file\_at\_commit ](/recipes/recipe_modules/git/api.py#3 4 )(self, file_path, commit_hash, remote_name=None, \*\*kwargs):**
— **def [cat\_file\_at\_commit ](/recipes/recipe_modules/git/api.py#3 3 )(self, file_path, commit_hash, remote_name=None, \*\*kwargs):**
Outputs the contents of a file at a given revision.
— **def [checkout ](/recipes/recipe_modules/git/api.py#10 7 )(self, url, ref=None, dir_path=None, recursive=False, submodules=True, submodule_update_force=False, keep_paths=None, step_suffix=None, curl_trace_file=None, raise_on_failure=True, set_got_revision=False, remote_name=None, display_fetch_size=None, file_name=None, submodule_update_recursive=True, use_git_cache=False, progress=True, tags=False, depth=None):**
— **def [checkout ](/recipes/recipe_modules/git/api.py#10 6 )(self, url, ref=None, dir_path=None, recursive=False, submodules=True, submodule_update_force=False, keep_paths=None, step_suffix=None, curl_trace_file=None, raise_on_failure=True, set_got_revision=False, remote_name=None, display_fetch_size=None, file_name=None, submodule_update_recursive=True, use_git_cache=False, progress=True, tags=False, depth=None):**
Performs a full git checkout and returns sha1 of checked out revision.
@ -493,7 +493,7 @@ Args:
Returns: If the checkout was successful, this returns the commit hash of
the checked-out-repo. Otherwise this returns None.
— **def [config\_get ](/recipes/recipe_modules/git/api.py#3 60 )(self, prop_name, \*\*kwargs):**
— **def [config\_get ](/recipes/recipe_modules/git/api.py#3 59 )(self, prop_name, \*\*kwargs):**
Returns git config output.
@ -503,7 +503,7 @@ Args:
Returns: (str) The Git config output, or None if no output was generated.
— **def [count\_objects ](/recipes/recipe_modules/git/api.py#4 2 )(self, previous_result=None, raise_on_failure=False, \*\*kwargs):**
— **def [count\_objects ](/recipes/recipe_modules/git/api.py#4 1 )(self, previous_result=None, raise_on_failure=False, \*\*kwargs):**
Returns `git count-objects` result as a dict.
@ -516,11 +516,11 @@ Args:
Returns:
A dict of count-object values, or None if count-object run failed.
— **def [fetch\_tags ](/recipes/recipe_modules/git/api.py#2 8 )(self, remote_name=None, \*\*kwargs):**
— **def [fetch\_tags ](/recipes/recipe_modules/git/api.py#2 7 )(self, remote_name=None, \*\*kwargs):**
Fetches all tags from the remote.
— **def [get\_remote\_url ](/recipes/recipe_modules/git/api.py#37 9 )(self, remote_name=None, \*\*kwargs):**
— **def [get\_remote\_url ](/recipes/recipe_modules/git/api.py#37 8 )(self, remote_name=None, \*\*kwargs):**
Returns the remote Git repository URL, or None.
@ -530,11 +530,11 @@ Args:
Returns: (str) The URL of the remote Git repository, or None.
— **def [get\_timestamp ](/recipes/recipe_modules/git/api.py#33 1 )(self, commit='HEAD', test_data=None, \*\*kwargs):**
— **def [get\_timestamp ](/recipes/recipe_modules/git/api.py#33 0 )(self, commit='HEAD', test_data=None, \*\*kwargs):**
Find and return the timestamp of the given commit.
— **def [ls\_remote ](/recipes/recipe_modules/git/api.py#47 2 )(self, url, ref, name=None, \*\*kwargs):**
— **def [ls\_remote ](/recipes/recipe_modules/git/api.py#47 1 )(self, url, ref, name=None, \*\*kwargs):**
Request the head revision for a given ref using ls-remote. Raise a
StepFailure if the ref does not exist, or more than one ref was found.
@ -546,7 +546,7 @@ Args:
Returns: A git revision.
— **def [new\_branch ](/recipes/recipe_modules/git/api.py#40 4 )(self, branch, name=None, upstream=None, upstream_current=False, \*\*kwargs):**
— **def [new\_branch ](/recipes/recipe_modules/git/api.py#40 3 )(self, branch, name=None, upstream=None, upstream_current=False, \*\*kwargs):**
Runs git new-branch on a Git repository, to be used before git cl
upload.
@ -558,7 +558,7 @@ Args:
* upstream_current (bool): whether to use '--upstream_current'.
* kwargs: Forwarded to '__call__'.
— **def [number ](/recipes/recipe_modules/git/api.py#43 5 )(self, commitrefs=None, test_values=None):**
— **def [number ](/recipes/recipe_modules/git/api.py#43 4 )(self, commitrefs=None, test_values=None):**
Computes the generation number of some commits.
@ -575,7 +575,7 @@ A list of strings containing the generation numbers of the commits.
If non-empty commitrefs was provided, the order of the returned
numbers will correspond to the order of the provided commitrefs.
— **def [rebase ](/recipes/recipe_modules/git/api.py#3 40 )(self, name_prefix, branch, dir_path, remote_name=None, \*\*kwargs):**
— **def [rebase ](/recipes/recipe_modules/git/api.py#3 39 )(self, name_prefix, branch, dir_path, remote_name=None, \*\*kwargs):**
Runs rebase HEAD onto branch