這是因為創建repo時選擇了建立readme
此時readme沒有和本機同步
所以必須先和remote同步
sol:
git remote add origin //your github url
//pull those changes
git pull origin master
//now, push your work to your new repo
git push origin master
git pull origin master時
error: Your local changes to the following files would be overwritten by merge:index.rtf必須先commitgit commit -m "index.rtf"git pull origin mastergit push origin master大功告成!
沒有留言:
張貼留言