denshoproject / ddr-cmdln

Command-line tools for automating the Densho Digital Repository's various processes.
Other
0 stars 2 forks source link

Replace git-filter-branch with git-filter-repo #212

Closed gjost closed 2 years ago

gjost commented 2 years ago

When you get to the second phase of a ddr-filter run, git prints out this message:

2022-05-05T10:48:50:616113301 - Running git filter-branch                                                                                                                    
WARNING: git-filter-branch has a glut of gotchas generating mangled history                                                                                                  
         rewrites.  Hit Ctrl-C before proceeding to abort, then use an                                                                                                       
         alternative filtering tool such as 'git filter-repo'                                                                                                                
         (https://github.com/newren/git-filter-repo/) instead.  See the                                                                                                      
         filter-branch manual page for more details; to squelch this warning,                                                                                                
         set FILTER_BRANCH_SQUELCH_WARNING=1.                                                                                                                                
Proceeding with filter-branch...         

The Git-scm site has this to say about git-filter-branch:

git filter-branch has a plethora of pitfalls that can produce non-obvious manglings of the intended history rewrite (and can leave you with little time to investigate such problems since it has such abysmal performance). These safety and performance issues cannot be backward compatibly fixed and as such, its use is not recommended. Please use an alternative history filtering tool such as git filter-repo. If you still need to use git filter-branch, please carefully read SAFETY (and PERFORMANCE) to learn about the land mines of filter-branch, and then vigilantly avoid as many of the hazards listed there as reasonably possible.

gjost commented 2 years ago

Converted to Click command on 212-ddrfilter branch.

gjost commented 2 years ago

Froh: we don't actually use git-filter-branch any more, so don't need to do this.