Package gbp :: Package scripts :: Module import_orig :: Class ImportOrigDebianGitRepository
[hide private]
[frames] | no frames]

Class ImportOrigDebianGitRepository

                  object --+        
                           |        
git.repository.GitRepository --+    
                               |    
     deb.git.DebianGitRepository --+
                                   |
                                  ImportOrigDebianGitRepository

Like a DebianGitRepository but can also perform rollbacks and knows about some of the inner workings upstream vcs_tag, …

Instance Methods [hide private]
 
__init__(self, *args, **kwargs)
x.__init__(...) initializes x; see help(type(x)) for signature
 
has_rollbacks(self)
 
vcs_tag_parent(self, vcs_tag_format, version)
If linking to the upstream VCS get the commit id
 
rrr(self, refname, action, reftype)
Remember ref for rollback
 
rrr_branch(self, branchname, action='reset-or-delete')
 
rrr_tag(self, tagname, action='delete')
 
rrr_merge(self, commit, action='abortmerge')
 
rollback(self)
Perform a complete rollback

Inherited from deb.git.DebianGitRepository: create_pristinetar_commits, debian_version_from_upstream, find_version, has_pristine_tar_branch, tree_drop_dirs, tree_get_dir

Inherited from git.repository.GitRepository: archive, clean, collect_garbage, force_head, get_author_info, get_config, is_clean, is_empty, rev_parse, set_user_email, set_user_name, status

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

    Branches and Merging
 
create_branch(self, *args, **kwargs)
Create a new branch
 
merge(self, *args, **kwargs)
Merge changes from the named commit into the current branch

Inherited from git.repository.GitRepository: abort_merge, branch_contains, delete_branch, get_branch, get_local_branches, get_merge_base, get_merge_branch, get_remote_branches, get_upstream_branch, has_branch, is_fast_forward, rename_branch, set_branch, set_upstream_branch, update_ref

Inherited from git.repository.GitRepository (private): _get_branches

    Tags
 
create_tag(self, *args, **kwargs)
Create a new tag.

Inherited from git.repository.GitRepository: delete_tag, describe, find_branch_tag, find_tag, get_tags, has_tag, move_tag, verify_tag

    Trees

Inherited from git.repository.GitRepository: checkout, get_obj_type, has_treeish, list_tree, make_tree, write_tree

    Remote Repositories

Inherited from git.repository.GitRepository: add_remote_repo, fetch, get_remote_repos, get_remotes, has_remote_repo, pull, push, push_tag, remove_remote_repo

    Files

Inherited from git.repository.GitRepository: add_files, list_files, remove_files, write_file

    Comitting
 
commit_dir(self, *args, **kwargs)
Replace the current tip of branch branch with the contents from unpack_dir

Inherited from git.repository.GitRepository: commit_all, commit_files, commit_staged, commit_tree

Inherited from git.repository.GitRepository (private): _commit

    Commit Information

Inherited from git.repository.GitRepository: get_commit_info, get_commits, get_subject, grep_log, show

    Patches

Inherited from git.repository.GitRepository: apply_patch, diff, diff_status, format_patches

    Submodules

Inherited from git.repository.GitRepository: add_submodule, get_submodules, has_submodules, update_submodules

Class Methods [hide private]

Inherited from deb.git.DebianGitRepository: tag_to_version, version_to_tag

    Repository Creation

Inherited from git.repository.GitRepository: clone, create

Static Methods [hide private]

Inherited from git.repository.GitRepository: strip_sha1

Class Variables [hide private]

Inherited from deb.git.DebianGitRepository: version_mangle_re

Instance Variables [hide private]

Inherited from git.repository.GitRepository (private): _bare, _path

Properties [hide private]

Inherited from deb.git.DebianGitRepository: pristine_tar_branch

Inherited from git.repository.GitRepository: bare, branch, git_dir, head, path, tags

Inherited from object: __class__

Method Details [hide private]

__init__(self, *args, **kwargs)
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • path - path to git repo (or subdir)
  • toplevel - whether path points to the toplevel dir of git repository
Raises:
Overrides: object.__init__
(inherited documentation)

rrr(self, refname, action, reftype)

 

Remember ref for rollback

Parameters:
  • refname - ref to roll back
  • action - the rollback action (delete, reset, ...)
  • reftype - the reference type (tag, branch, ...)

rollback(self)

 

Perform a complete rollback

Try to roll back as much as possible and remember what failed.

create_tag(self, *args, **kwargs)

 

Create a new tag.

Parameters:
  • name - the tag's name
  • msg - The tag message.
  • commit - the commit or object to create the tag at, default is HEAD
  • sign - Whether to sing the tag
  • keyid - the GPG keyid used to sign the tag
Overrides: git.repository.GitRepository.create_tag
(inherited documentation)

commit_dir(self, *args, **kwargs)

 

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

Parameters:
  • unpack_dir - content to add
  • msg - commit message to use
  • branch - branch to add the contents of unpack_dir to
  • other_parents - additional parents of this commit
  • author - author information to use for commit
  • committer - committer information to use for commit
  • create_missing_branch - create branch as detached branch if it doesn't already exist.
Overrides: git.repository.GitRepository.commit_dir
(inherited documentation)

create_branch(self, *args, **kwargs)

 

Create a new branch

Parameters:
  • branch - the branch's name
  • rev - where to start the branch from
  • force - reset branch HEAD to start point, if it already exists

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

Overrides: git.repository.GitRepository.create_branch
(inherited documentation)

merge(self, *args, **kwargs)

 

Merge changes from the named commit into the current branch

Parameters:
  • commit - the commit to merge from (usually a branch name or tag)
  • verbose - whether to print a summary after the merge
  • edit - whether to invoke an editor to edit the merge message
Overrides: git.repository.GitRepository.merge
(inherited documentation)