git 常用命令
来源:互联网 发布:键盘美化软件下载 编辑:程序博客网 时间:2024/05/01 12:45
克隆远程仓库:git clone https://github.com/wenziyelang/curl_baidu.git mylibgit增加一个文件:git add test.txt提交一个文件:git commit -m "这是注释"查看状态:git status编辑文件:vim test.txt查看文件内容:cat test.txt上传本地当前分支代码到master分支 git push origin master上传本地所有分支代码到远程对应的分支 git push查看分支 git branch -a创建分支 git branch name切换分支 git checkout name创建并切换 git checkout -b name合并某分支到当前分支 git merge name删除分支 git branch -d name$ git config --global user.name "John Doe"$ git config --global user.email johndoe@example.com$ git config list$ git config uer.namegit help <verb>$ git <verb> --help$ man git-<verb>git help config查看一下分支合并日志:git log --graph --pretty=oneline --abbrev-commit 回到过去版本: git reset --hard master@{1}修改了,没有git add,已提交过 想撤销这次修改,git checkout a.txt or /src/修改了,已git add,git reset a.txt撤销到某一个版本,但是当前暂存区、工作区不想撤销,git reset --soft commitId如果修改了某几个文件到暂存区,想撤销到某个commit,git reset --hard commitIdgit can-file -p HEADgit stash git stash pop
0 0
- git 常用命令
- Git常用命令
- git 常用命令
- git 常用命令
- git 常用命令
- git 常用命令
- GIT常用命令
- git 常用命令
- git 常用命令
- Git 常用命令
- git 常用命令
- Git常用命令
- Git常用命令
- git 常用命令
- Git 常用命令
- git常用命令
- git 常用命令
- Git 常用命令
- xcode文件找不到---“AFNetworking.h”file not found
- ListView中的Item点击事件和子控件的冲突或者item点击没有反应的解决办法
- android 源码各版本下载 原生纯净版
- 二叉树中的最大路径和
- iOS UI初级-UIVew与UIWindow
- git 常用命令
- Linux命令中的rmdir
- Rectangle Area
- iOS UI初级-常用UI控件
- iOS开发中的小技巧
- linux下mysql默认安装目录和常用命令
- git 克隆远程仓库并创建分支、提交分支、获取分支
- HDU 5405 Sometimes Naive 2015多校联合训练赛#9 LCT 树链剖分
- 每天都好困的说