Skip to content

Instantly share code, notes, and snippets.

What would you like to do?

git addi

Add git files interactively from the command line.



Step 1

Add the following alias to your global .gitconfig file

    addi = !git add $(git status --porcelain | fzf -m | awk '{print $2}')

* The ! tells git to run an external command instead of a subcommand.

Step 2

Run git addi. To select multiple files, use Shift + Tab. Press ENTER when done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment