02-01: Git Concepts
Matt Price
In this section
collaboration
remotes
branches
commits
worktree vs. repository
Collaboration
Concepts: Remote
Classroom Network
Branches
git history is a
tree
, not a straight line
nothing is ever lost!!
can be hard to figure out!
Concepts: Commit
changes aren't saved automatically; manually “commit”
every commit can be revisited later
a branch is really just a “pointer” to a specific commit (complicated)
Activity Commits
Concept: Worktree and Repository
what you see
what's underneath
Pointers and objects (git is a
database
)
5e7ed7e34f9a8b34d26f98275a21afdcac171b83
Git Workflows
In this section
merging
pulling
pushing
Concepts: Merge
when we “merge” two branches, the changes from one are brought over into the other
if work has progressed on
both
branches, then there might be incompatible changes
these are called "merge conflicts"
they suck!
Concepts: Pull and Push Changes
Concepts: Pull and Push collaboratively
Pull and Push, the repo, and the worktree
pulling
attempts to impose changes
from a branch in one repo onto a branch in another repo.
first it adds the
commit objects
from the remote object into its own store of objects
then it tries to
update the pointer at the tip the branch
if it succeds, yay!
if not – conflict, and new commits will be created after conflicts are resolved.