0

It is seems that Repository.checkout can only checkout a referenece.
Can we checkout any revision in the repo by SHA1-hash?
equivalent to "svn checkout -r" in subversion system

Zoe
  • 27,060
  • 21
  • 118
  • 148
user3196254
  • 115
  • 1
  • 6

1 Answers1

0

The Repository.checkout() method does only accept references or reference names, but that's by far not the only checkout method. There's Repository.checkout_tree() which lets you specify which treeish you want to check out (so you can pass a tree, a commit or a tag).

Carlos Martín Nieto
  • 5,207
  • 1
  • 15
  • 16