I am trying to migrate a repository from Bitbucket to GitHub which fails due to an error in the tree.
git fsck
gives the following output:
Checking object directories: 100% (256/256), done.
warning in tree 86b6f36a93c983faab565674a0b92f93fb22cfc7: nullSha1: contains entries pointing to null sha1
error in tree 86b6f36a93c983faab565674a0b92f93fb22cfc7: duplicateEntries: contains duplicate file entries
Checking the malicious tree hash with git ls-tree 86b6f36a93c983faab565674a0b92f93fb22cfc7
Gives me--among others--these lines:
160000 commit 0000000000000000000000000000000000000000 foobar
040000 tree 2abdf38e2288bca8be24df800372c6a96ecef111 foobar
I know that the first line stands for a deleted sub module. I would like to remove the reference to this from the history to allow me to push this to GitHub.