Introduction


Figure 1

An XKCD comic about the git control system.

Figure 2

A diagram showing the relationship between the working directory, staging area, and repository in git.
Staging Area

Figure 3

A diagram showing the components that make up a git commit.
What is in a Commit

Figure 4

Review 2
Review 2

Branches


Figure 1

A diagram showing branching in a theoretical git repository.
Git Branching: An example of how branches of a repository are based on each other and evolve over time. (Source: Atlassian Git Tutorial)

Figure 2

A diagram showing several commits on a single branch in a theoretical git repository.
Git Branching: A branch is just a “named pointer” to a commit. (Source: Atlassian Git Tutorial)

Figure 3

A diagram showing a new branch pointer in a theoretical git repository.
Git Branching: The new branch is pointing to the same commit from which it was branched off. (Source: Atlassian Git Tutorial)

Remote Repositories


Figure 1

A diagram showing a local git repository with remote connections to two other repositories.
Remote Schematic

Undoing Changes


Figure 1

A diagram showing a repository before and after reverting the last commit.
git revert

Figure 2

A diagram showing a repository before and after resetting the last commit.
git reset

Figure 3

A diagram showing a repository before and after using git checkout to move to a previous commit.
git checkout

Merging


Figure 1

A diagram showing different types of Git merges.
Merging diagram.

Tags


Branching Models


Forking Workflow


Figure 1

A diagram showing the forking workflow with upstream, origin, and local repositories.
Forking Workflow

Figure 2

Screenshot of the button array in the top right corner of the Github interface with the fork button highlighted.{alt=A cropped screenshot of the Github UI showing the array of buttons on the top right of the project home page with the fork button highlighted.}


Figure 3

Screenshot of the button array in the top right corner of the Gitlab interface with the fork button highlighted.{alt=A cropped screenshot of the Gitlab UI showing the array of buttons on the top right of the project home page with the fork button highlighted.}


Data Science Workflow


Figure 1

GitFlow 1GitFlow 1GitFlow 1GitFlow 1GitFlow 1 :::::::::::::::::::::::::::::::::::::::: keypoints


Large Files


Undo, Move, cherry-pickWhat is a cherry-pick?


Figure 1

GitFlow 1GitFlow 1GitFlow 1


Interactive Rebase and Squash


Figure 1

GitFlow 1GitFlow 1GitFlow 1GitFlow 1


Hooks


Figure 1

GitFlow 1
GitFlow 1

Setting up the Command Prompt


Additional Resources


Figure 1

ExternalGITKGitHub