一.git常用命令
1.初始化本地库
git init

2.查看状态
git status

3.添加暂存区
git add 文件名

4.删除暂存区
git rm --cached 文件名

5. 提交本地库
git commit -m "提交说明" 文件名

6.查看日志
git relog 查看精简日志
git log 查看详细日志


7.版本穿越
git reset --hard 版本号

二.分支操作
1.查看分支
git branch -v

2.添加分支
git branch 分支名

3.切换分支
git checkout 分支名

4.合并分支
git merge 分支名

当代码冲突,打开文件



三.github操作
1.创建链接别名
git remote add 别名 链接

2. push推送本地库
git push 别名 分支

3.拉取代码
git pull 别名 分支

被折叠的 条评论
为什么被折叠?



