Read tree and move HEAD in checkout
This commit is contained in:
@@ -97,6 +97,12 @@ def commit(message):
|
||||
return oid
|
||||
|
||||
|
||||
def checkout(oid):
|
||||
commit = get_commit(oid)
|
||||
read_tree(commit.tree)
|
||||
data.set_HEAD(oid)
|
||||
|
||||
|
||||
Commit = namedtuple("Commit", ["tree", "parent", "message"])
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user