git基本简单命令

1.初始化git 目录:

git init

2.添加文件到暂存:

git add ./

3.提交:

git commit -m "first commit"

4.提交之后没有推送,想撤回:

git reset --soft HEAD~1

后面的1表示撤回上一次提交
5.推送:

git push

6.拉取

git pull

7.提交文件到上一次的提交里:

git commit –-amend –-no-edit

你可能感兴趣的:(git)