git: BFG installation

isaacadams

Isaac Adams

Posted on March 4, 2021

git: BFG installation

BFG Repo Cleaner is both faster and easier to use than using git filter-branch. It handles simple use cases for editing sensitive information in git.

Invoking BFG

BFG is a .jar file that is invoked from the command line using java.

$ java -jar path/to/bfg.jar

Invoking BFG this way can become tedious...

Easier way to reference BFG?

To simplify it, consider creating an alias

.bashrc

...
alias bfg='java -jar path/to/bfg.jar'
Enter fullscreen mode Exit fullscreen mode

BFG is now invokable from the command line in any directory:

$ bfg ...

πŸ’– πŸ’ͺ πŸ™… 🚩
isaacadams
Isaac Adams

Posted on March 4, 2021

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related

To Rebase or not to Rebase?
git To Rebase or not to Rebase?

October 11, 2024

git: BFG installation
git git: BFG installation

March 4, 2021