Skip to content

Commit 32a0b39

Browse files
committed
repo: Upgrade: use branch or commit
1 parent 2c82e98 commit 32a0b39

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

newt/repo/repo.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -323,6 +323,10 @@ func (r *Repo) Upgrade(ver newtutil.RepoVersion) error {
323323
return err
324324
}
325325

326+
if branch := r.downloader.MainBranch(); branch != "" {
327+
commit = branch
328+
}
329+
326330
if err := r.updateRepo(commit); err != nil {
327331
return err
328332
}

0 commit comments

Comments
 (0)