How Git Works: an editable mindmap
Explore How Git Works as an editable mindmap. Follow color-coded branches for Working tree, Stage, Commit history, Share, Resolve conflicts, with supporting ideas and curved connections.
A mindmap of How Git Works, with the main ideas arranged around a central topic and connections that show how they relate.
How Git Works: an editable mindmap
The interactive MindMap canvas for this explanation — every lane, row and arrow above is a real QueryChart diagram you can open and edit.
How to read this mindmap
- Begin at “How Git Works” in the centre, then explore any branch that answers your question. The branch colors keep each group of ideas together.
- Curved lines show relationships; arrowheads appear only where one idea leads to another. Select any idea in the editor to change its text, position, or connections.
Working tree
This branch brings together “Developer edits files in the working directory”.
Stage
This branch brings together “git add moves changes into the staging area”.
Commit history
This branch brings together “A commit is a snapshot of the whole repository plus metadata — author, message, timestamp. Git only stores the delta against the parent, so history stays small.”, “Git stores the commit with a pointer to its parent”, “The branch pointer moves to the new commit”.
Share
This branch brings together “The commit graph is what makes Git a distributed tool: everyone has the full history locally, and ‘push’ and ‘pull’ only exchange the missing pieces.”, “Remote repository records the new history”, “History is shared and up to date”.
Resolve conflicts
This branch brings together “Git merges divergent histories automatically when the changes touch different files or lines. Only overlapping edits produce a conflict.”, “Merge conflict — developer resolves it manually”.
Connections across the map
A commit is a full snapshot linked to its parent, which is what makes the history an append-only graph.
A branch is a pointer to a commit, not a container of changes: creating and switching branches is cheap for that reason.
Staging is the deliberate middle step that lets you choose what a commit contains.
Git is distributed: everyone holds the full history locally, and push/pull only exchange the missing pieces.
Conflicts are the exception, not the rule, and when they happen, a human resolves them explicitly.
Key relationships and takeaways
- A commit is a full snapshot linked to its parent, which is what makes the history an append-only graph.
- A branch is a pointer to a commit, not a container of changes: creating and switching branches is cheap for that reason.
- Staging is the deliberate middle step that lets you choose what a commit contains.
- Git is distributed: everyone holds the full history locally, and push/pull only exchange the missing pieces.
- Conflicts are the exception, not the rule, and when they happen, a human resolves them explicitly.
When to use this visual
- Teaching the snapshot model to a team that has only ever used Git as a sequence of commands.
- Explaining branches, merges and conflicts through the pointer model rather than memorised commands.
- Grounding a review of a team's commit and branching workflow in how history is actually structured.
How it works
Start at the central topic
Rename “How Git Works” if you want to adapt this map to a specific project or lesson.
Develop the branches
Edit the supporting ideas, then add examples and notes where a branch needs more detail.
Connect related ideas
Draw curved connections across branches; use an arrow only when the relationship has a direction.
Frequently asked questions
What is Git and how is it different from other version control?
Git is a distributed version control system based on snapshots. Each commit stores a complete picture of the repository plus a pointer to its parent, rather than just a list of file changes. Because every developer has the full history locally, most operations work offline, and collaboration is a matter of exchanging commits with remotes.
What is a branch in Git?
A branch is a movable pointer to a commit. When you commit on a branch, the pointer advances to the new commit; the commit itself does not know or care which branch it is on. That is why creating a branch is instant and why switching between branches only changes which snapshot your working directory shows.
Why does Git have a staging area?
The staging area lets you build a commit deliberately. You can edit several files, stage only the ones that belong together, and commit that selection, leaving unrelated work uncommitted. The working directory, staging area and repository are three separate states, which is exactly the pipeline the visual draws.
How does Git resolve merge conflicts?
When two branches change different files, or different lines, Git merges them automatically. When they change the same lines, Git cannot guess which version is right, so it marks the conflict and asks a human to choose. The conflict is a decision, not a failure, which is why the visual routes it to an explicit resolution step before history is shared.
Edit this mindmap in QueryChart
Open this mindmap as your own editable free canvas. Move ideas, add branches, and draw new connections.