This page has notes about git
, including what it is and how to use it.
Overview
git
is a tool used to manage code. A git
“repository” is simply a folder of code that is “version-controlled”; meaning having versions, etc. Software developers use git
for many reasons, including:
- Controlling how changes get incorporated into the code. In general, we want to make sure all new changes are double checked!
- Rolling back changes. Maybe a bug got introduced and we need to rollback!
- Knowing who made a specific change to the code. This can help us know who to ask about a particular piece of code.
git
!= GitHub! GitHub is an “online repository host” forgit
, meaning that it can store yourgit
repositories online!- We sync our code with GitHub to share our code with others. This means that when coding, we continually pull changes from GitHub (usually from other people) and push changes to GitHub.
Getting Started
- Install
git
from here - Set up your identity. See here for instructions
- Ensure you are authenticated with GitHub. See GitHub CLI for one way to do this.