Show Menu
Cheatography

git Cheat Sheet (DRAFT) by

learn git from https://www.youtube.com/watch?v=DVRQoVRzMIY

This is a draft cheat sheet. It is a work in progress and is not finished yet.

Branch

List branch
git branch
Add new branch
git branch <br­anc­h_n­ame>
Switch branch
git checkout <br­anc­h_n­ame>
Rename branch
git branch -m <ol­d_n­ame> <ne­w_n­ame­>>

Work flow

Create git repo local
git init
Add all files to
git add .
Add files to
git add <fi­le_­nam­e>
Save changes
git commit -m "­<co­mme­nt_­her­e>"