1
1
mirror of https://github.com/go-gitea/gitea synced 2025-08-13 13:08:19 +00:00

Fix missing reference prefix of commits when sync mirror repository (#24994)

replace #24868
just a patch to fix #24824 in v1.19.4
The reference name of commits when synchronizing should also has prefix
like refs/heads/<branch-name>.
This commit is contained in:
sillyguodong
2023-05-30 13:12:21 +08:00
committed by GitHub
parent 7dc46ffbaa
commit 826b7b979c
2 changed files with 85 additions and 1 deletions

View File

@@ -143,7 +143,7 @@ func parseRemoteUpdateOutput(output string) []*mirrorSyncResult {
continue
}
results = append(results, &mirrorSyncResult{
refName: refName,
refName: git.BranchPrefix + refName, // the reference name of commits should also has prefix.
oldCommitID: shas[0],
newCommitID: shas[1],
})