Git命令简记

一,git 的几个区

1.index 缓存区

2.repository 本机仓库(正式区)

3.remote repository 远程仓库

二,git常用命令

git init *      创建本地仓库
git clone *      将整个仓库包括所有的分支信息复制在本地一份,一个新的分布式节点
git  add  *      本地缓存增加文件
git  commit *      缓存向本地仓库增加信息
git push *      向远程仓库增加信息
git fetch *      拉取到本地但不合并
git pull *      拉取到本地并合并
git merge *      合并
git branch *      分支管理      
官方文档:We use branches to experiment and make edits before committing them to main.
git checkout *      切换分支
原文地址:https://www.cnblogs.com/lxzbky/p/13502973.html