Trying to run git-filter-repo command from python. I can't figure out how this should be done.
git filter-repo --path README.md --path guides/ --path tools/releases
So far I have:
filtering_options = git_filter_repo.FilteringOptions.default_options()
filtering_options.source = _fragment_repo_git_directory(workspace, "svn-import")
filtering_options.target = _main_repo_git_directory(workspace).encode()
filtering_options.force = True
filtering_options.replace_refs = "update no add"
repo_filter = git_filter_repo.RepoFilter(
filtering_options,
# ?????????
)
repo_filter.run()
You can take inspiration from the
newren/git-filter-repo/contrib/filter-repo-demos/lint-history
script, which does use a callback function as your# ?????????
argument: