We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f57759d + 4896736 commit f955eb7Copy full SHA for f955eb7
contrib/filter-repo-demos/clean-ignore
@@ -18,6 +18,7 @@ near the top of git-filter-repo.
18
import argparse
19
import os
20
import subprocess
21
+import sys
22
try:
23
import git_filter_repo as fr
24
except ImportError:
@@ -65,7 +66,14 @@ class CheckIgnores:
65
66
commit.file_changes = [x for x in commit.file_changes
67
if x.filename not in bad]
68
-checker = CheckIgnores()
69
-args = fr.FilteringOptions.default_options()
70
-filter = fr.RepoFilter(args, commit_callback=checker.skip_ignores)
71
-filter.run()
+
+def main():
+ checker = CheckIgnores()
72
+ args = fr.FilteringOptions.parse_args(sys.argv[1:])
73
+ filter = fr.RepoFilter(args, commit_callback=checker.skip_ignores)
74
+ filter.run()
75
76
77
+if __name__ == '__main__':
78
+ main()
79
0 commit comments