=git========》命令大全

代码恢复修改(并且sync):
例drv目录:

cd drv/

git status

git clean

git clean -dxf

git status

git checkout --.

git status

上库操作命令:

git add file

git status .

git commit .

repo upload .

修改之后的提交操作命令:

git status .

git add file

git commit --amend

repo upload .

合并多个commit:

git rebase - i commit_id

id为要合并的commit之前的id

重置到某一次的提交:

git reset --hard commit_id

猜你喜欢

转载自www.cnblogs.com/hylogs/p/13374671.html