Workflows¶
Each guide follows one task from start to finish on the same example project: acme-api, a small Rust web service worked on by four people. It has feature branches, two release tags, a merge, a remote that has moved on, a stash and some work in progress. Every screenshot is rendered from the app itself on that repository.
| Task | Guide |
|---|---|
| Find a commit, a branch or who changed what | Find your way in the History tree |
| Read what a commit changed, file by file | Review a commit |
| Stage files, hunks or single lines and commit | Commit part of your work |
| Keep logs and build output out of Git | Ignore what should never be committed |
| Switch and create branches, fetch, pull and push | Branches, fetch, pull and push |
| Put work aside and bring it back | Park work in a stash |
| Reword, squash, fixup, drop and reorder commits | Clean up with interactive rebase |
| Finish a merge or rebase that stopped | Resolve a merge conflict |
| Get back a branch tip from before a rewrite | Undo with Recovery |
| See who changed a file or a few lines, and when | Follow a file |
| Mark a release | Tag a release |
| Copy a commit onto your branch, or undo one | Cherry-pick and revert |
| Move a branch back, keeping or discarding changes | Reset a branch |
| Check out a second branch in its own folder | Work on two branches at once |
| Update submodules, fetch LFS objects | Submodules and LFS |
| Sign your work, check others' signatures | Sign commits and tags |
| Get a repository, or start one | Clone or create a repository |
| Run any command from the keyboard, change keys | Search, keys and preferences |
Every command, three ways
Each action is in a menu, most have a key, and all of them can be found by name in search (Ctrl+K). The footer always lists the keys for the view you are in.