summaryrefslogtreecommitdiff
path: root/gbp/git.py
diff options
context:
space:
mode:
Diffstat (limited to 'gbp/git.py')
-rw-r--r--gbp/git.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/gbp/git.py b/gbp/git.py
index 66aec40..dbf918a 100644
--- a/gbp/git.py
+++ b/gbp/git.py
@@ -633,6 +633,15 @@ class GitRepository(object):
return sha[0].strip()
#{ Trees
+ def checkout(self, treeish):
+ """
+ Checkout treeish
+
+ @param treeish: the treeish to check out
+ @type treeish: C{str}
+ """
+ self._git_command("checkout", ["--quiet", treeish])
+
def has_treeish(self, treeish):
"""
Check if the repository has the treeish object I{treeish}.