I made a "git add dir" and then committed and pushed. Then I realized it was best to not add the directory to the repository, so I deleted it with "git rm -r". However, I want to delete it from the history, so that it cannot be recovered from the git repository.
I have looked at BFG Repo Cleaner, but
- for some reason the directory has been added as a submodule to git: it has a .git subdirectory and in the logs it shows "Subproject commit 72ab72...". Can BFG Repo Cleaner remove this submodule?
- BFG does not seem to support removing a given directory. --delete-folders takes a glob as a parameter, and since the directory has a common name it may remove other directories too.
What should I do?
Thank you.