git相关
来源:互联网 发布:redis做数据库 编辑:程序博客网 时间:2024/06/05 06:44
git常用命令:
1.git init
2.git add [filename]
3.git commit -m "[comment]"
4.git checkout -- [filename]
5.git reset HEAD [filename]
6.git reset --hard HEAD^
git reset --hard HEAD^^
git reset --hard HEAD~100
git reset --hard [commit-id]
7.git status
8.git log
git log --pretty=oneline
git log --graph --pretty=oneline
9.git reflog
10.git checkout -b [sub-branch-name]
git checkout [branch-name]
11.git stash
git stash list
git stash pop
12.git merge [branch-name]
git merge --no-ff -m "[comment]" [branch-name]
13.git branch -d [branch-name]
14.git remote add [remote-name] [remote-address]
15.git push -u [remote-name] [branch-name]
git push [remote-name] [branch-name]
16.git clone [remote-address]
17.git tag [tag-name]
git tag [tag-name] [commit-id]
git tag -a [tag-name] -m "[comment]"
18.git show [tag-name]
git tag
19.git tag -d [tag-name]
git push [remote-name] :refs/tags/[tag-name]
20.git push [remote-name] [tag-name]
git push [remote-name] --tags
21.git pull
22.git remote
git remote -v
23.git checkout -b [branch-name] [remote-name]/[branch-name]
24.git diff [filename] -- 若添加到了暂存库则查看的是和暂存库文件中的区别,若还没有放到暂存库,查看的是和版本库最新版本文件区别。
参考网址:https://www.liaoxuefeng.com/wiki/0013739516305929606dd18361248578c67b8067c8c017b000
- Git 相关
- git 相关
- git 相关
- git相关
- git相关
- Git相关
- Git相关
- git相关
- Git 相关
- Git相关
- git 相关
- git相关
- git 相关
- git相关
- git相关
- Git 相关
- git 相关
- git 相关
- java线程安全之同步类容器与并发类容器(十二)
- 摩尔定律还有效吗?
- Signal ()函数详细介绍
- vue学习之路(一)--vue-cli安装+vue-router+vue-resource
- Unity开发微信登陆—利用ShareSDK微信登录
- git相关
- Sublime Text3注册码(测试可用仅供个人学习)
- [Matlab]Invalid mex-file 找不到指定的模块
- python 学习心得
- angularjs(ng-repeat和filter)生成多级菜单
- 软件更新,是不是太频繁了?
- JXL基础应用
- 学习笔记DL003:神经网络第二、三次浪潮,数据量、模型规模,精度、复杂度,对现实世界冲击
- MongoDB环境搭建