Source metadata
- Type: Textbook
- Authors: Scott Chacon and Ben Straub
- Edition: 2nd edition
- Publisher: Apress (freely available at git-scm.com/book)
- Coverage used: Chapters 1–3 (Getting Started, Git Basics, Git Branching) and Chapter 6 (GitHub); Chapters 4–5 and 7–10 skipped as out of scope for beginner Unity use
Key takeaways
- Git stores snapshots of the whole project at each commit, not deltas — this makes switching between states fast and reliable
- Nearly every Git operation is local; network connection only needed for push/pull/fetch
- Every file is in one of three states: modified → staged → committed, corresponding to three areas: working tree, staging area, .git directory
- Branches are lightweight movable pointers to commits — creating one is instant and costs almost nothing
- Fast-forward merge moves a pointer; three-way merge creates a new commit from two diverged histories
- GitHub’s Pull Request model enables code review and team discussion before merging; works both for public contributions (fork model) and internal teams (collaborator model)
- The Unity
.gitignoremust excludeLibrary/,Temp/,obj/, andLogs/— these are regenerated automatically and bloat repositories severely if committed
Notable claims
“Git thinks of its data more like a series of snapshots of a miniature filesystem. Every time you commit, or save the state of your project, Git basically takes a picture of what all your files look like at that moment and stores a reference to that snapshot.”
“The basic Git workflow goes something like this: you modify files in your working tree. You selectively stage just the changes you want to be part of your next commit. And you do a commit, which takes the files as they are in the staging area and stores that snapshot permanently to your Git directory.”
“GitHub is designed around a particular collaboration workflow, centered on Pull Requests. This flow works whether you’re collaborating with a tightly-knit team in a single shared repository, or a globally-distributed company or network of strangers.”
Relevance
This source grounds all four Git/GitHub wiki pages. The scope was deliberately restricted to beginner content relevant to Unity students: version control concepts, daily commands, branching and merging, and GitHub collaboration. Advanced topics (Git on servers, rebasing, submodules, git internals, email patches) were not extracted.
Open questions raised
- Unity-specific
.gitignoretemplates have evolved — the patterns here are correct but students should also check Unity’s official recommended.gitignorefor their engine version - Git LFS (Large File Storage) is not covered here but is relevant for Unity projects with large binary assets (audio, textures, 3D models) — worth a dedicated page if teams report repository size issues
- GitHub Desktop (GUI client) is not covered — may be worth a brief comparison page for students who prefer not to use the command line
Links
Pages grounded by this source:
- git-concepts — snapshots, three states, three areas
- git-workflow — daily commands, .gitignore, remotes
- git-branching — branches, fast-forward, three-way merge, conflict resolution
- git-github-unity — GitHub account setup, repository creation, Unity .gitignore, Pull Requests