Git & GitHub Cheat Sheet

This content was generated with the assistance of AI and should be verified against the official documentation before being relied on in production; see the section bibliography for the reference material consulted while preparing these pages.

A single-page, colour-coded summary of the Git and GitHub essentials — installing and configuring Git, creating or cloning a repository, the three areas (working tree, staging area, repository) and the file lifecycle, staging and committing, inspecting history, undoing changes, branch commands, the checkout/switch/restore split, stashing, tags and GitHub releases, remotes (fetch/pull/push, -u, --force-with-lease), merging and rebasing with conflict resolution, GitHub flow in six steps, and pull requests with the GitHub CLI and the three merge methods — plus a strip of IntelliJ IDEA and VS Code shortcuts and commands. It reflects Git 2.55.x, GitHub CLI 2.101.x, IntelliJ IDEA 2026.2 and current stable VS Code with the GitHub Pull Requests and Issues extension.

For the full explanation, every option, and additional examples, see the dedicated pages: