Part of lp.code.interfaces.githosting View In Hierarchy
Method | create | Create a Git repository. |
Method | getProperties | Get properties of this repository. |
Method | setProperties | Set properties of this repository. |
Method | getRefs | Get all refs in this repository. |
Method | getCommits | Get details of a list of commits. |
Method | getLog | Get commit log information. |
Method | getDiff | Get the diff between two commits. |
Method | getMergeDiff | Get the merge preview diff between two commits. |
Method | detectMerges | Detect merges of any of 'sources' into 'target'. |
Method | delete | Delete a repository. |
Method | getBlob | Get a blob by file name from a repository. |
Parameters | path | Physical path of the new repository on the hosting service. |
clone_from | If not None, clone the new repository from this other physical path. |
Parameters | path | Physical path of the repository on the hosting service. |
Returns | A dict of properties. |
Parameters | path | Physical path of the repository on the hosting service. |
props | Properties to set. |
Parameters | path | Physical path of the repository on the hosting service. |
exclude_prefixes | An optional list of ref prefixes to exclude. | |
Returns | A dict mapping ref paths to dicts representing the objects they point to. |
Parameters | path | Physical path of the repository on the hosting service. |
commit_oids | A list of commit OIDs. | |
logger | An optional logger. | |
Returns | A list of dicts each of which represents one of the requested commits. Non-existent commits will be omitted. |
Parameters | path | Physical path of the repository on the hosting service. |
start | The commit to start listing from. | |
limit | If not None, return no more than this many commits. | |
stop | If not None, ignore this commit and its ancestors. | |
logger | An optional logger. | |
Returns | A list of dicts each of which represents a commit from the start commit's history. |
Parameters | path | Physical path of the repository on the hosting service. |
old | The OID of the old commit. | |
new | The OID of the new commit. | |
common_ancestor | If True, return the symmetric or common
ancestor diff, equivalent to
git diff $(git-merge-base OLD NEW) NEW . | |
context_lines | Include this number of lines of context around each hunk. | |
logger | An optional logger. | |
Returns | A dict mapping 'commits' to a list of commits between 'old'
and 'new' (formatted as with getCommits ) and 'patch' to the
text of the diff between 'old' and 'new'. |
Parameters | path | Physical path of the repository on the hosting service. |
base | The OID of the base commit. | |
head | The OID of the commit that we want to merge into 'base'. | |
logger | An optional logger. | |
Returns | A dict mapping 'commits' to a list of commits between
'base' and 'head' (formatted as with getCommits ), 'patch' to
the text of the diff between 'base' and 'head', and 'conflicts'
to a list of conflicted paths. |
Parameters | path | Physical path of the repository on the hosting service. |
target | The OID of the merge proposal target commit. | |
sources | The OIDs of the merge proposal source commits. | |
logger | An optional logger. | |
Returns | A dict mapping merged commit OIDs from 'sources' to the first commit OID in the left-hand (first parent only) history of 'target' that is a descendant of the corresponding source commit. Unmerged commits are omitted. |
Parameters | path | Physical path of the repository on the hosting service. |
logger | An optional logger. |
Parameters | path | Physical path of the repository on the hosting service. |
filename | Relative path of a file in the repository. | |
rev | An optional revision. Defaults to 'HEAD'. | |
logger | An optional logger. | |
Returns | A binary string with the blob content. |