git-filter-repo command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
git-filter-repo: command not found
or when using sudo you get the following error message
sudo: git-filter-repo: command not found
Solutions to git-filter-repo: command not found
How To Fix git-filter-repo: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu git-filter-repo is provided by git-filter-repo package.
git-filter-repo is:
git filter-repo is a versatile tool for rewriting history, which includes capabilities 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.
While most users will probably just use filter-repo as a simple command line tool (and likely only use a few of its flags), at its core filter-repo contains a library for creating history rewriting tools. As such, users with specialized needs can leverage it to quickly create entirely new history rewriting tools.
To fix this problem, we can install more using the command below.
sudo apt-get -y install git-filter-repo
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install git-filter-repo.
sudo apt -y install git-filter-repo
Or if you have aptitude installed you can use the following command.
sudo aptitude install git-filter-repo
Summary
In this tutorial we learn how to fix git-filter-repo command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.