Permanently removing binary files from GitLab repos

Hi everyone,

We have a GitLab-hosted repo at work that contains some large binary files that we’d like to remove. I know of tools such as BFG Repo-Cleaner which will remove a file from a Git repository. Tools such as this are effective at removing unwanted files from a Git repo. But, I’m wondering what the impact might be of using a tool like this with a repo hosted in GitLab? As I understand it, these tools re-write history and change commit IDs. In our commits, we cite issue numbers using the # syntax, and our issues contain references to our commits.

If we used BFG Repo-Cleaner to remove some files, and our commit IDs are changed, what would be the impact in terms of GitLab and the association between our commits and our issues? Does anyone know of a better way to remove files from the history of a repo hosted with GitLab?

Thanks,

John

Hello,

you can find a very helpful guide on stackoverflow

Cheers

Hi karlmarx80, thanks for your reply! The link you posted is definitely a thorough explanation of removing binary files from Git repos.

It looks like all of those approaches would re-write history and change all of the commit IDs. Since we reference issues in our commit messages, and GitLab keeps track of the commits within the issues using SHA1 commit IDs, what might be the impact on GitLab of re-writing all of those commit IDs, and is there a way to mitigate it?

Thanks,

John