Illustrate how Git works

##Summary
This article illustrates the most commonly used commands in Git.

##Basic The
Insert picture description here
above four commands copy files between the working directory, the temporary storage directory (also called the index) and the warehouse.

git add files puts the current file into the temporary storage area.
git commit generates a snapshot to the staging area and submits it.
git reset-files are used to undo the last
git add files. You can also use git reset to undo all temporary area files.
git checkout-files copies files from the temporary storage area to the working directory to discard local modifications.
You can use git reset -p, git checkout -p, or git add -p to enter interactive mode. You can also skip the temporary storage area and directly take out the files from the warehouse or submit the code directly.

For details, see https://mp.weixin.qq.com/s/HFZIePZlx8UgfsVM9EjQ-w

Guess you like

Origin blog.csdn.net/ximenjianxue/article/details/113813554