Technology Git Commands

Learn with diagrams, code, systems and practical examples.

</>
Command family

Git commands

Use these references to understand what a command changes, predict its effect, recover from mistakes, and choose safer alternatives when appropriate.

git revert

Learn git revert through shared-history reasoning, inverse commits, conflict recovery, no-commit workflows, and the special risks of reverting merges.

Learn this command →

git rebase

Learn git rebase through commit-graph reasoning, safe examples, conflict recovery, interactive cleanup, and practical guidance on when rebasing is the wrong choice.

Learn this command →

git merge

Learn git merge through commit-graph reasoning, fast-forward behavior, merge commits, conflict recovery, and safe collaboration scenarios.

Learn this command →

git restore

Learn git restore through working-tree and index state reasoning, safe unstaging, source selection, patch mode, and deliberate recovery from local file mistakes.

Learn this command →

git reset

Learn git reset through HEAD, index, and working-tree reasoning, safe soft/mixed/hard examples, unstaging, recovery, and clear reset-vs-restore-vs-revert decisions.

Learn this command →

git stash

Learn git stash through working-tree and index state reasoning, selective stashing, safe restoration, conflict recovery, and practical branch workflows.

Learn this command →

git cherry-pick

Learn git cherry-pick through commit selection, backport reasoning, conflict recovery, merge-parent choices, and safe verification of copied changes.

Learn this command →

git reflog

Learn git reflog as local ref-movement history for recovering commits after resets, rebases, branch moves, and other history-changing operations.

Learn this command →