Use the proper ref instead of always assuming it's a 'head' (might be a 'tag')
This commit is contained in:
parent
90cab55fec
commit
9f83f0f384
@ -59,7 +59,7 @@ func main() {
|
||||
}
|
||||
|
||||
err = w.Checkout(&git.CheckoutOptions{
|
||||
Branch: plumbing.ReferenceName("refs/heads/" + refName),
|
||||
Branch: plumbing.ReferenceName(ref),
|
||||
})
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
|
Loading…
x
Reference in New Issue
Block a user