Known subclasses: gbp.pkg.git.PkgGitRepository

Represents a git repository at path. It's currently assumed that the git repository is stored in a directory named .git/ below path.

RaisesGitRepositoryErroron git errors GitRepositoryError is raised by all methods.
Method __init__ No summary
Method path The absolute path to the repository
Method git_dir The absolute path to git's metadata
Method bare Whether this is a bare repository
Method tags List of all tags in the repository
Method branch The currently checked out branch
Method head SHA1 of the current HEAD
Method rename_branch Rename branch
Method create_branch Create a new branch
Method delete_branch Delete branch branch
Method get_branch On what branch is the current working copy
Method has_branch Check if the repository has branch named branch.
Method set_branch Switch to branch branch
Method get_merge_branch Get the branch we'd merge from
Method get_merge_base Get the common ancestor between two commits
Method merge Merge changes from the named commit into the current branch
Method abort_merge Abort a merge
Method is_in_merge Undocumented
Method is_fast_forward Check if an update from from_branch to to_branch would be a fast forward or if the branch is up to date already.
Method get_local_branches Get a list of local branches
Method get_remote_branches Get a list of remote branches
Method update_ref Update ref ref to commit new if ref currently points to old
Method branch_contains Check if branch branch contains commit commit
Method set_upstream_branch Set upstream branches for local branch
Method get_upstream_branch Get upstream branch for the local branch
Method create_tag Create a new tag.
Method delete_tag Delete a tag named tag
Method move_tag Undocumented
Method has_tag Check if the repository has a tag named tag.
Method describe Describe commit, relative to the latest tag reachable from it.
Method find_tag Find the closest tag to a given commit
Method find_branch_tag Find the closest tag on a certain branch to a given commit
Method get_tags List tags
Method verify_tag Verify a signed tag
Method force_head Force HEAD to a specific commit
Method is_clean Does the repository contain any uncommitted modifications?
Method clean Remove untracked files from the working tree.
Method status Check status of repository.
Method is_empty Is the repository empty?
Method rev_parse Find the SHA1 of a given name
Static Method strip_sha1 Strip a given sha1 and check if the resulting hash has the expected length.
Method checkout Checkout treeish
Method has_treeish Check if the repository has the treeish object treeish.
Method write_tree Create a tree object from the current index
Method make_tree Create a tree based on contents.
Method get_obj_type Get type of a git repository object
Method list_tree Get a trees content. It returns a list of objects that match the 'ls-tree' output: [mode, type, sha1, path].
Method get_config Gets the config value associated with name
Method set_config Set a git config value in this repository
Method set_user_name Sets the full name to use for git commits.
Method set_user_email Sets the email address to use for git commits.
Method get_author_info Determine a sane values for author name and author email from git's config and environment variables.
Method get_remotes Get a list of remote repositories
Method get_remote_repos Get all remote repositories
Method has_remote_repo Do we know about a remote named name?
Method add_remote_repo Add a tracked remote repository
Method remove_remote_repo Undocumented
Method fetch Download objects and refs from another repository.
Method pull Fetch and merge from another repository
Method push Push changes to the remote repo
Method push_tag Push a tag to the remote repo
Method add_files Add files to a the repository
Method remove_files Remove files from the repository
Method list_files List files in index and working tree
Method write_file Hash a single file and write it into the object database
Method rename_file Rename file, directory, or symlink
Method commit_staged Commit currently staged files to the repository
Method commit_all No summary
Method commit_files Commit the given files to the repository
Method commit_dir Replace the current tip of branch branch with the contents from unpack_dir
Method commit_tree Commit a tree with commit msg msg and parents parents
Method get_commits Get commits from since to until touching paths
Method show Show a git object
Method grep_log Get commmits matching regex
Method get_subject Gets the subject of a commit.
Method get_commit_info Look up data of a specific commit-ish. Dereferences given commit-ish to the commit it points to.
Method format_patches Output the commits between start and end as patches in output_dir.
Method apply_patch Apply a patch using git apply
Method diff Diff two git repository objects
Method diff_status Get file-status of two git repository objects
Method archive Create an archive from a treeish
Method collect_garbage Cleanup unnecessary files and optimize the local repository
Method has_submodules Does the repo have any submodules?
Method add_submodule Add a submodule
Method update_submodules Update all submodules
Method get_submodules List the submodules of treeish
Class Method create Create a repository at path
Class Method clone Clone a git repository at remote to path.
Instance Variable _path The path to the working tree (type: str)
Instance Variable _bare Whether this is a bare repository (type: bool)
Method _check_bare Check whether this is a bare repository
Method _get_git_dir Undocumented
Method _check_repo Undocumented
Static Method __build_env Prepare environment for subprocess calls
Method _git_getoutput Run a git command and return the output
Method _git_inout Run a git command with input and return output
Class Method __git_inout As _git_inout but can be used without an instance
Method _git_command Execute git command with arguments args and environment env at path.
Method _cmd_has_feature Check if the git command has certain feature enabled.
Method _get_branches Get a list of branches
Method _status Undocumented
Method _commit Undocumented
_path =
The path to the working tree (type: str)
_bare =
Whether this is a bare repository (type: bool)
def _check_bare(self):

Check whether this is a bare repository

def _get_git_dir(self):
Undocumented
def _check_repo(self, path, toplevel):
Undocumented
def __init__(self, path, toplevel=True):
Parameterspathpath to git repo (or subdir) (type: str)
toplevelwhether path points to the toplevel dir of git repository (type: bool)
@staticmethod
def __build_env(extra_env):

Prepare environment for subprocess calls

def _git_getoutput(self, command, args=[], extra_env=None, cwd=None):

Run a git command and return the output

Parameterscommandgit command to run (type: str)
argslist of arguments (type: list)
extra_envextra environment variables to pass (type: dict)
cwddirectory to switch to when running the command, defaults to self.path (type: str)
Returnsstdout, return code (type: tuple of list of bytestr and int)
Unknown Field: deprecateduse gbp.git.repository.GitRepository._git_inout instead.
def _git_inout(self, command, args, input=None, extra_env=None, cwd=None, capture_stderr=False, config_args=None):

Run a git command with input and return output

Parameterscommandgit command to run (type: str)
inputinput to pipe to command (type: str)
argslist of arguments (type: list)
extra_envextra environment variables to pass (type: dict)
cwddirectory to switch to when running the command, defaults to self.path (type: str)
capture_stderrwhether to capture stderr (type: bool)
Returnsstdout, stderr, return code (type: tuple of bytestr, bytestr, int)
@classmethod
def __git_inout(cls, command, args, input, extra_env, cwd, capture_stderr, config_args=None):

As _git_inout but can be used without an instance

def _git_command(self, command, args=[], extra_env=None):

Execute git command with arguments args and environment env at path.

Parameterscommandgit command (type: str)
argscommand line arguments (type: list)
extra_envextra environment variables to set when running command (type: dict)
def _cmd_has_feature(self, command, feature):

Check if the git command has certain feature enabled.

Parameterscommandgit command (type: str)
featurefeature / command option to check (type: str)
ReturnsTrue if feature is supported (type: bool)
@property
def path(self):

The absolute path to the repository

@property
def git_dir(self):

The absolute path to git's metadata

@property
def bare(self):

Whether this is a bare repository

@property
def tags(self):

List of all tags in the repository

@property
def branch(self):

The currently checked out branch

@property
def head(self):

SHA1 of the current HEAD

def rename_branch(self, branch, newbranch):

Rename branch

Parametersbranchname of the branch to be renamed
newbranchnew name of the branch
def create_branch(self, branch, rev=None, force=False):

Create a new branch

Parametersbranchthe branch's name
revwhere to start the branch from
forcereset branch HEAD to start point, if it already exists

If rev is None the branch starts from the current HEAD.

def delete_branch(self, branch, remote=False):

Delete branch branch

Parametersbranchname of the branch to delete (type: str)
remotedelete a remote branch
remotebool
def get_branch(self):

On what branch is the current working copy

Returnscurrent branch or None in an empty repo (type: str)
RaisesGitRepositoryErrorif HEAD is not a symbolic ref (e.g. when in detached HEAD state)
def has_branch(self, branch, remote=False):

Check if the repository has branch named branch.

Parametersbranchbranch to look for
remoteonly look for remote branches (type: bool)
ReturnsTrue if the repository has this branch, False otherwise (type: bool)
def set_branch(self, branch):

Switch to branch branch

Parametersbranchname of the branch to switch to (type: str)
def get_merge_branch(self, branch):

Get the branch we'd merge from

Returnsrepo and branch we would merge from (type: str)
def get_merge_base(self, commit1, commit2):

Get the common ancestor between two commits

Parameterscommit1commit SHA1 or name of a branch or tag (type: str)
commit2commit SHA1 or name of a branch or tag (type: str)
ReturnsSHA1 of the common ancestor (type: str)
def merge(self, commit, verbose=False, edit=False):

Merge changes from the named commit into the current branch

Parameterscommitthe commit to merge from (usually a branch name or tag) (type: str)
verbosewhether to print a summary after the merge (type: bool)
editwhether to invoke an editor to edit the merge message (type: bool)
def abort_merge(self):

Abort a merge

def is_in_merge(self):
Undocumented
def is_fast_forward(self, from_branch, to_branch):

Check if an update from from_branch to to_branch would be a fast forward or if the branch is up to date already.

Returnscan_fast_forward, up_to_date (type: tuple)
def _get_branches(self, remote=False):

Get a list of branches

Parametersremotewhether to list local or remote branches (type: bool)
Returnslocal or remote branches (type: list)
def get_local_branches(self):

Get a list of local branches

Returnslocal branches (type: list)
def get_remote_branches(self):

Get a list of remote branches

Returnsremote branches (type: list)
def update_ref(self, ref, new, old=None, msg=None):

Update ref ref to commit new if ref currently points to old

Parametersrefthe ref to update (type: str)
newthe new value for ref (type: str)
oldthe old value of ref (type: str)
msgthe reason for the update (type: str)
def branch_contains(self, branch, commit, remote=False):

Check if branch branch contains commit commit

Parametersbranchthe branch the commit should be on (type: str)
committhe str commit to check (type: str)
remotewhether to check remote instead of local branches (type: bool)
def set_upstream_branch(self, local_branch, upstream):

Set upstream branches for local branch

Parameterslocal_branchname of the local branch (type: str)
upstreamRemote branch in the form remote/branch, e.g. origin/master (type: str)
def get_upstream_branch(self, local_branch):

Get upstream branch for the local branch

Parameterslocal_branchname fo the local branch (type: str)
Returnsupstream (remote/branch) or '' if no upstream found (type: str)
def create_tag(self, name, msg=None, commit=None, sign=False, keyid=None):

Create a new tag.

Parametersnamethe tag's name (type: str)
msgThe tag message. (type: str)
committhe commit or object to create the tag at, default is HEAD (type: str)
signWhether to sing the tag (type: bool)
keyidthe GPG keyid used to sign the tag (type: str)
def delete_tag(self, tag):

Delete a tag named tag

Parameterstagthe tag to delete (type: str)
def move_tag(self, old, new):
Undocumented
def has_tag(self, tag):

Check if the repository has a tag named tag.

Parameterstagtag to look for (type: str)
ReturnsTrue if the repository has that tag, False otherwise (type: bool)
def describe(self, commitish, pattern=None, longfmt=False, always=False, abbrev=None, tags=False, exact_match=False):

Describe commit, relative to the latest tag reachable from it.

Parameterscommitishthe commit-ish to describe (type: str)
patternonly look for tags matching pattern (type: str)
longfmtdescribe the commit in the long format (type: bool)
alwaysreturn commit sha1 as fallback if no tag is found (type: bool)
abbrevabbreviate sha1 to given length instead of the default (type: None or long)
tagsenable matching a lightweight (non-annotated) tag (type: bool)
exact_matchonly output exact matches (a tag directly references the supplied commit) (type: bool)
Returnstag name plus/or the abbreviated sha1 (type: str)
def find_tag(self, commit, pattern=None):

Find the closest tag to a given commit

Parameterscommitthe commit to describe (type: str)
patternonly look for tags matching pattern (type: str)
Returnsthe found tag (type: str)
def find_branch_tag(self, commit, branch, pattern=None):

Find the closest tag on a certain branch to a given commit

Parameterscommitthe commit to describe (type: str)
patternonly look for tags matching pattern (type: str)
Returnsthe found tag (type: str)
def get_tags(self, pattern=None):

List tags

Parameterspatternonly list tags matching pattern (type: str)
Returnstags (type: list of str)
def verify_tag(self, tag):

Verify a signed tag

Parameterstagthe tag's name (type: str)
ReturnsWhether the signature on the tag could be verified (type: bool)
def force_head(self, commit, hard=False):

Force HEAD to a specific commit

Parameterscommitcommit to move HEAD to
hardalso update the working copy (type: bool)
def _status(self, porcelain, ignore_untracked, paths):
Undocumented
def is_clean(self, ignore_untracked=False, paths=None):

Does the repository contain any uncommitted modifications?

Parametersignore_untrackedwhether to ignore untracked files when checking the repository status (type: bool)
pathsonly check changes on paths (type: list of stings)
ReturnsTrue if the repository is clean, False otherwise and Git's status message (type: tuple)
def clean(self, directories=False, force=False, dry_run=False):

Remove untracked files from the working tree.

Parametersdirectoriesremove untracked directories, too (type: bool)
forcesatisfy git configuration variable clean.requireForce (type: bool)
dry_rundon’t actually remove anything (type: bool)
def status(self, pathlist=None):

Check status of repository.

ParameterspathlistList of paths to check status for (type: list @return dict of lists of paths, where key is a git status flag. @rtype dict)
def is_empty(self):

Is the repository empty?

ReturnsTrue if the repositorydoesn't have any commits, False otherwise (type: bool)
def rev_parse(self, name, short=0):

Find the SHA1 of a given name

Parametersnamethe name to look for (type: str)
shorttry to abbreviate SHA1 to given length (type: int)
Returnsthe name's sha1 (type: str)
@staticmethod
def strip_sha1(sha1, length=0):

Strip a given sha1 and check if the resulting hash has the expected length.

>>> GitRepository.strip_sha1('  58ef37dbeb12c44b206b92f746385a6f61253c0a\n')
'58ef37dbeb12c44b206b92f746385a6f61253c0a'
>>> GitRepository.strip_sha1('58ef37d', 10)
Traceback (most recent call last):
...
gbp.git.repository.GitRepositoryError: '58ef37d' is not a valid sha1 of length 10
>>> GitRepository.strip_sha1('58ef37d', 7)
'58ef37d'
>>> GitRepository.strip_sha1('123456789', 7)
'123456789'
>>> GitRepository.strip_sha1('foobar')
Traceback (most recent call last):
...
gbp.git.repository.GitRepositoryError: 'foobar' is not a valid sha1
def checkout(self, treeish):

Checkout treeish

Parameterstreeishthe treeish to check out (type: str)
def has_treeish(self, treeish):

Check if the repository has the treeish object treeish.

Parameterstreeishtreeish object to look for (type: str)
ReturnsTrue if the repository has that tree, False otherwise (type: bool)
def write_tree(self, index_file=None):

Create a tree object from the current index

Parametersindex_filealternate index file to read changes from (type: str)
Returnsthe new tree object's sha1 (type: str)
def make_tree(self, contents):

Create a tree based on contents.

Parameterscontentssame format as GitRepository.list_tree output. (type: list of str)
def get_obj_type(self, obj):

Get type of a git repository object

Parametersobjrepository object (type: str)
Returnstype of the repository object (type: str)
def list_tree(self, treeish, recurse=False, paths=None):

Get a trees content. It returns a list of objects that match the 'ls-tree' output: [mode, type, sha1, path].

Parameterstreeishthe treeish object to list (type: str)
recursewhether to list the tree recursively (type: bool)
Returnsthe tree (type: list of objects. See above.)
def get_config(self, name):

Gets the config value associated with name

Parametersnameconfig value to get
Returnsfetched config value (type: str)
def set_config(self, name, value):

Set a git config value in this repository

def set_user_name(self, name):

Sets the full name to use for git commits.

Parametersnamefull name to use
def set_user_email(self, email):

Sets the email address to use for git commits.

Parametersemailemail address to use
def get_author_info(self):

Determine a sane values for author name and author email from git's config and environment variables.

Returnsname and email (type: GitModifier)
def get_remotes(self):

Get a list of remote repositories

Returnsremote repositories (type: dict of GitRemote)
def get_remote_repos(self):

Get all remote repositories

Returnsremote repositories (type: list of str)
Unknown Field: deprecatedUse get_remotes() instead
def has_remote_repo(self, name):

Do we know about a remote named name?

Parametersnamename of the remote repository (type: str)
ReturnsTrue if the remote repositore is known, False otherwise (type: bool)
def add_remote_repo(self, name, url, tags=True, fetch=False):

Add a tracked remote repository

Parametersnamethe name to use for the remote (type: str)
urlthe url to add (type: str)
tagswhether to fetch tags (type: bool)
fetchwhether to fetch immediately from the remote side (type: bool)
def remove_remote_repo(self, name):
Undocumented
def fetch(self, repo=None, tags=False, depth=0, refspec=None, all_remotes=False):

Download objects and refs from another repository.

Parametersreporepository to fetch from (type: str)
tagswhether to fetch all tag objects (type: bool)
depthdeepen the history of (shallow) repository to depth depth (type: int)
refspecrefspec to use instead of the default from git config (type: str)
all_remotesfetch all remotes (type: bool)
def pull(self, repo=None, ff_only=False, all_remotes=False):

Fetch and merge from another repository

Parametersreporepository to fetch from (type: str)
ff_onlyonly merge if this results in a fast forward merge (type: bool)
all_remotesfetch all remotes (type: bool)
def push(self, repo=None, src=None, dst=None, ff_only=True, force=False, tags=False, dry_run=False):

Push changes to the remote repo

Parametersreporepository to push to (type: str)
srcthe source ref to push (type: str)
dstthe name of the destination ref to push to (type: str)
ff_onlyonly push if it's a fast forward update (type: bool)
forceforce push, can cause the remote repository to lose commits; use it with care (type: bool)
tagspush all refs under refs/tags, in addition to other refs (type: bool)
dry_rundry run (type: bool)
def push_tag(self, repo, tag, dry_run=False):

Push a tag to the remote repo

Parametersreporepository to push to (type: str)
tagthe name of the tag (type: str)
dry_rundry run (type: bool)
def add_files(self, paths, force=False, index_file=None, work_tree=None):

Add files to a the repository

Parameterspathslist of files to add (type: list or str)
forceadd files even if they would be ignored by .gitignore (type: bool)
index_filealternative index file to use
work_treealternative working tree to use
def remove_files(self, paths, verbose=False):

Remove files from the repository

Parameterspathslist of files to remove
pathslist or str
verbosebe verbose (type: bool)
def list_files(self, types=['cached']):

List files in index and working tree

Parameterstypeslist of types to show (type: list)
Returnslist of files as byte string (type: list of str)
def write_file(self, filename, filters=True):

Hash a single file and write it into the object database

Parametersfilenamethe filename to the content of the file to hash (type: bytestr)
filterswhether to run filters (type: bool)
Returnsthe hash of the file (type: str)
def rename_file(self, old, new):

Rename file, directory, or symlink

def _commit(self, msg, args=[], author_info=None):
Undocumented
def commit_staged(self, msg, author_info=None, edit=False):

Commit currently staged files to the repository

Parametersmsgcommit message (type: str)
author_infoauthorship information (type: GitModifier)
editwhether to spawn an editor to edit the commit info (type: bool)
def commit_all(self, msg, author_info=None, edit=False):

Commit all changes to the repository

Parametersmsgcommit message (type: str)
author_infoauthorship information (type: GitModifier)
def commit_files(self, files, msg, author_info=None):

Commit the given files to the repository

Parametersfilesfile or files to commit (type: str or list)
msgcommit message (type: str)
author_infoauthorship information (type: GitModifier)
def commit_dir(self, unpack_dir, msg, branch, other_parents=None, author={}, committer={}, create_missing_branch=False):

Replace the current tip of branch branch with the contents from unpack_dir

Parametersunpack_dircontent to add (type: str)
msgcommit message to use (type: str)
branchbranch to add the contents of unpack_dir to (type: str)
other_parentsadditional parents of this commit (type: list of str)
authorauthor information to use for commit (type: dict with keys name, email, date)
committercommitter information to use for commit (type: dict with keys name, email, date or GitModifier)
create_missing_branchcreate branch as detached branch if it doesn't already exist. (type: bool)
def commit_tree(self, tree, msg, parents, author={}, committer={}):

Commit a tree with commit msg msg and parents parents

Parameterstreetree to commit
msgcommit message
parentsparents of this commit
authorauthorship information (type: dict with keys 'name' and 'email' or GitModifier)
committercommitter information (type: dict with keys 'name' and 'email')
def get_commits(self, since=None, until=None, paths=None, num=0, first_parent=False, options=None):

Get commits from since to until touching paths

Parameterssincecommit to start from (type: str)
untillast commit to get (type: str)
pathsonly list commits touching paths (type: list of str)
nummaximum number of commits to fetch (type: int)
optionslist of additional options passed to git log (type: list of strings)
first_parentonly follow first parent when seeing a merge commit (type: bool)
def show(self, id):

Show a git object

Returns (type: bytestr)
def grep_log(self, regex, since=None, merges=True):

Get commmits matching regex

Parametersregexregular expression (type: str)
sincewhere to start grepping (e.g. a branch) (type: str)
def get_subject(self, commit):

Gets the subject of a commit.

Parameterscommitthe commit to get the subject from
Returnsthe commit's subject (type: str)
Unknown Field: deprecatedUse get_commit_info directly
def get_commit_info(self, commitish):

Look up data of a specific commit-ish. Dereferences given commit-ish to the commit it points to.

Parameterscommitishthe commit-ish to inspect
Returnsthe commit's including id, author, email, subject and body (type: dict)
def format_patches(self, start, end, output_dir, signature=True, thread=None, symmetric=True):

Output the commits between start and end as patches in output_dir.

This outputs the revisions start...end by default. When using symmetric to false it uses start..end instead.

Parametersstartthe commit on the left side of the revision range
endthe commit on the right hand side of the revisino range
output_dirdirectory to write the patches to
signaturewhether to output a signature
threadwhether to include In-Reply-To references
symmetricwhether to use the symmetric difference (see above)
def apply_patch(self, patch, index=True, context=None, strip=None, fix_ws=False):

Apply a patch using git apply

def diff(self, obj1, obj2=None, paths=None, stat=False, summary=False, text=False, ignore_submodules=True, abbrev=None, renames=False):

Diff two git repository objects

Parametersobj1first object (type: str)
obj2second object (type: str)
pathsList of paths to diff (type: list)
statShow diffstat (type: bool or int or str)
summaryShow diffstat (type: bool)
textGenerate textual diffs, treat all files as text (type: bool)
ignore_submodulesignore changes to submodules (type: bool)
Returnsdiff (type: binary)
def diff_status(self, obj1, obj2):

Get file-status of two git repository objects

Parametersobj1first object (type: str)
obj2second object (type: str)
Returnsname-status (type: defaultdict of str)
def archive(self, format, prefix, output, treeish, cwd=None):

Create an archive from a treeish

Parametersformatthe type of archive to create, e.g. 'tar.gz' (type: str)
prefixprefix to prepend to each filename in the archive (type: str)
outputthe name of the archive to create (type: str)
treeishthe treeish to create the archive from (type: str)
cwdThe directory to run in. Defaults to the current dir (type: str)
def collect_garbage(self, auto=False, prune=False, aggressive=False):

Cleanup unnecessary files and optimize the local repository

param auto: only cleanup if required param auto: bool

def has_submodules(self, treeish=None):

Does the repo have any submodules?

Parameterstreeishlook into treeish (type: str)
ReturnsTrue if the repository has any submodules, False otherwise (type: bool)
def add_submodule(self, repo_path):

Add a submodule

Parametersrepo_pathpath to submodule (type: str)
def update_submodules(self, init=True, recursive=True, fetch=False):

Update all submodules

Parametersinitwhether to initialize the submodule if necessary (type: bool)
recursivewhether to update submodules recursively (type: bool)
fetchwhether to fetch new objects (type: bool)
def get_submodules(self, treeish, path=None, recursive=True):

List the submodules of treeish

Returnsa list of submodule/commit-id tuples (type: list of tuples)
@classmethod
def create(cls, path, description=None, bare=False):

Create a repository at path

Parameterspathwhere to create the repository (type: str)
barewhether to create a bare repository (type: bool)
Returnsgit repository object (type: GitRepository)
@classmethod
def clone(cls, path, remote, depth=0, recursive=False, mirror=False, bare=False, auto_name=True, reference=None):

Clone a git repository at remote to path.

Parameterspathwhere to clone the repository to (type: str)
remoteURL to clone (type: str)
depthcreate a shallow clone of depth depth (type: int)
recursivewhether to clone submodules (type: bool)
mirrorwhether to pass --mirror to git-clone (type: bool)
barewhether to create a bare repository (type: bool)
auto_nameIf True create a directory below path based on the remotes name. Otherwise create the repo directly at path. (type: bool)
referencecreate a clone using local objects from reference repository (type: str)
Returnsgit repository object (type: GitRepository)
API Documentation for git-buildpackage, generated by pydoctor at 2018-08-19 08:52:02.