← back to flaviocopes.com

Git command finder

← All tools

Type what you want to do — "undo last commit", "rename branch", "stash changes" — or browse by category. Each entry has the command, a one-line explanation, and a caution when the operation is destructive.

~~~

Search

Categories

~~~

Commands

Placeholders like <file> and <branch-name> are meant to be replaced. Commands run in your terminal — this page only looks them up.

~~~

About this tool

Git has hundreds of subcommands and flags. This catalog focuses on the tasks you actually Google: undo a commit, fix a branch name, recover after a reset, push safely after a rebase. Search by plain-English goal, not by memorizing git syntax.

Destructive commands (reset --hard, force push, clean -fd) include a caution line. When in doubt, run git reflog first — it is the undo button for your undo button.

~~~

Read more