Quardah
Quardah

Reputation: 323

Github migration duplicates commit, one for code and one for tags, must reassociate tags with proper commit

We moved a repository from one Github to another and for some reason the commits were duplicated, one for the code and one for the tags.

In the source instance i have commit xxxxxx with both the code and the tags, in the destination instance i have commit xxxxxx for the code and yyyyyy for the tags.

Note that xxxxxx follows the right branch (main) and yyyyyy follows a fictional (?) branch that we can see in sourcetree. Every commits in the history where we did use tags is now duplicated. The "tags" commits follow each other the same as the "code" commits follow each other.

It causes issues with LFS and so we would like to bring back everything tagged as yyyyyy to xxxxxx.

Like this :

yyyyyy2 and xxxxxx2 -> xxxxxx2
yyyyyy1 and xxxxxx1 -> xxxxxx1

and so on...

In the UI if we click on the commit associated with the tags we get the error message :

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

In short, we need to force the associated commit on every migrated tags to the right commit.

How can we do that on Github enterprise?

Thanks.

Upvotes: 0

Views: 27

Answers (0)

Related Questions