-
Notifications
You must be signed in to change notification settings - Fork 1
Git cookbook
rd084c edited this page Apr 14, 2014
·
10 revisions
为了让公司内部的开发人员迅速了解如何使用git以及github 常用操作列举如下(以git@github.com:iTianchuang/cookbook.git为例):
git clone git@github.com:iTianchuang/cookbook.git
- 检查工作区状态
git status - 检查某次提交
git show COMMIT - 比较某个文件 (工作区和待提交区)
git diff file
- 添加文件到准备区
git add file - 提及变更
git commit -m "comments here." - 与github上进行同步
git pull - 推送到github
git push
git log --diff-filter=D --summary
git checkout COMMIT^ -- file
vi ~/.gitconfig
[diff]
tool = bc3
[difftool "bc3"]
cmd = \"E:/PortApps/Beyond Compare 3/bcomp.exe\" -expandall -solo \"$LOCAL\" \"$REMOTE\”
git difftool