• Home
  • Raw
  • Download

Lines Matching full:git

18     """Exceptions raised for general git errors."""
22 """Exceptions raised for git clone errors."""
26 """Exception raised for git fetch errors."""
30 """Exception raised for git pull errors."""
34 """Exception raised for git reset errors."""
38 """Exception raised for git commit errors."""
43 This class represents a git repo.
45 It is used to pull down a local copy of a git repo, check if the local
55 @param giturl: master repo git url.
57 @param abs_work_tree: work tree of the git repo. In the
58 absence of a work tree git manipulations will occur
60 In such repos the -git-dir option should point to
61 the .git directory and -work-tree should point to
65 (.git) in the same directory. This class assumes non-bare
70 'git repository')
75 "a web URL for your git repos", DeprecationWarning)
77 # path to .git dir
78 self.gitpath = utils.sh_escape(os.path.join(self.repodir,'.git'))
80 # Find git base command. If not found, this will throw an exception
81 self.git_base_cmd = os_dep.command('git')
96 'constructed with a git URL.')
102 The command we use to run git cannot be set. It is reconstructed
105 # base git command , pointing to gitpath git dir
106 gitcmdbase = '%s --git-dir=%s' % (self.git_base_cmd,
129 Wrapper for a git command.
131 @param cmd: Git subcommand (ex 'clone').
148 logging.error('git command failed: %s: %s',
170 logging.info('Cloning git repo %s', self.giturl)
180 raise GitCloneError('Failed to clone git url', rv)
191 @param rebase: If true forces git pull to perform a rebase instead of a
195 logging.info('Updating git repo %s', self.giturl)
204 e_msg = 'Failed to pull git repo data'
222 Reset repo to the given branch or git sha.
224 @param branch_or_sha: Name of a local or remote branch or git sha.
235 Reset repo to HEAD@{0} by running git reset --hard HEAD.
279 # stale. (e.g., you just untarred the whole git folder that you got from
311 This method overrides baseclass get so we can do proper git
313 this method will leave an up-to-date version of git repo at
334 Get the top commit hash of the current local git branch.
336 @return: Top commit hash of local git branch
345 Get the top commit hash of the current remote git branch.
347 @return: Top commit hash of remote git branch
374 Return whether the git repo was already initialized.
376 Counts objects in .git directory, since these will exist even if the
431 raise error.CmdError('Failed to find git sha1 revision', gitlog)
438 Check out the git commit id, branch, or tag given by remote.
444 @note: For git checkout tag git version >= 1.5.0 is required
457 raise error.CmdError('Failed to checkout git branch', gitlog)
482 raise error.CmdError('Failed to get git branch', gitlog)