Git-filter-repo is a command-line utility designed for the permanent modification and restructuring of Git repository history. It functions as a maintenance tool for cleaning project data, enabling users to reorganize file structures, update commit metadata, and purge sensitive information such as credentials or large blobs from the entire commit graph.
The tool distinguishes itself by interacting directly with the internal Git object database rather than relying on standard command-line interfaces. It utilizes the native fast-import stream protocol and processes commits as a continuous data stream, which allows for efficient in-memory tree transformations and rapid history rewriting even in large repositories.
This utility supports comprehensive version control refactoring, facilitating the migration of legacy projects or the splitting of repositories into smaller components. It provides a systematic approach to maintaining repository security and size by ensuring that historical changes are applied consistently across all commits. The software is distributed as a Python script and is intended for use in automated repository maintenance workflows.