source: https://github.com/newren/git-filter-repo
Git Filter-Repo
git filter-repo is a versatile tool for rewriting history, which includes capabilities I have not found anywhere else. It roughly falls into the same space of tool as git filter-branch but without the capitulation-inducing poor performance, with far more capabilities, and with a design that scales usability-wise beyond trivial rewriting cases. git filter-repo is now recommended by the git project instead of git filter-branch.
Installing on Windows
- Copy to a folder that is in the path.
- Move Python 3 to front of Path (so it gets executed when typing “python”)
- Deactivate the installation-on-demand handling for Python.exe and Python3.exe under Start > Manage app execution Aliases
- Make sure the first line of git_filter_repo reads:
#!/usr/bin/env python
git filter-repo -h
Test by running
git filter-repo -h