编程学习网 > 程序人生 > 解决github报错:src refspec master does not match any Github
2014
11-11

解决github报错:src refspec master does not match any Github

When i try to push my first project, i got this message " error: src refspec master does not match any ". After browsing a litte, i found that this problem happen because i don't have initial commit yet. I just fork from empty Git Project ( brand new Git project ).

To solve this kind of problem, do this :

git init
git add README
git commit -m "Initial commit."
git remote add origin git@github.com:username/your-project.git
git push origin master

and it works for me!

扫码二维码 获取免费视频学习资料

Python编程学习

查 看2022高级编程视频教程免费获取