代码提交:
1.ctil+tab:唤起switcher页面,接着把tab换成t,让光标跳到Terminal
2.输入git status
查看当前状态,然后输入 git add .
(提交当前目录所有更改) 或者 git add your.file
(提交指定的文件:your.file),将修改过或者新增的源代码提交到缓存区
3.接着输入git commit -m "提交备注"
-> 推送到远程:git push
4.切换分支:git checkout
,如果有没git add
的文件,会无法检出
4.1暂存文件,然后切换分支,再弹出暂存
5.总结:
git status
git add . / git add your.file
git commit -m “提交备注”
git push
git stash push -m “smart checkout”
git checkout
git stash pop