场景
有时候我们不想提交本地的配置文件,只想提交部分我们修改的文件
做法
1. 查看文件状态
git status
image.png
2. 提交需要提交的文件
git add 需要提交的文件路径
image.png
3.忽略其它文件
git stash -u -k
image.png
4. commit
git commit -m “修改”
5.拉取合并
git pull
6. 推送
git push
7. 恢复之前忽略的文件
git stash pop










网友评论