Message 'src refspec master does not match any' when pushing commits in Git

前端 未结 30 1735
轮回少年
轮回少年 2020-11-22 02:49

I clone my repository with:

git clone ssh://xxxxx/xx.git 

But after I change some files and add and commit them,

30条回答
  •  北海茫月
    2020-11-22 02:53

    My issue was that the 'master' branch hadn't been created locally yet.

    A quick

    git checkout -b "master"
    

    created the master branch, at which point, a quick

    git push -u origin master
    

    pushed the work up to the Git repository.

提交回复
热议问题