Git报错:Your branch is up to date with 'origin/master'.


Git在提交的时候报错 Your branch is up to date with 'origin/master'.

报错 Your branch is up to date with 'origin/master'. 具体如下:

原因:为了测试创建了空文件夹test、然后直接添加、然后提交就报错、直接原因是因为你的test文件夹为空

解决:在你的test文件夹中创建一个文件就OK了

1、	进入到test文件夹中
> cd ./test
2、	创建一个空文件 1.txt
> touch 1.txt
3、	退回到项目根目录下
> cd ../
4、	重修添加、提交、会发现提交成功
> git add ./test
> git commit -m "提交测试文件夹 test"


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM