Ask a Question
Ask Question Login
Corporate Training
  1. Community
  2. Devops
  3. Question
Devops

error: src refspec master does not match any when pushing commits in Git

Asked by Natalie Downing Jul 15, 2021 4.2K views 1 answer
Share

About this question

 I clone my repository with:

git clone ssh://xxxxx/xx.git 

But after I change some files and add and commit them, I want to push them to the server:

git add xxx.php
git commit -m "TEST"
git push origin master

But the error I get back is:

error: src refspec master does not match any.  
error: failed to push some refs to 'ssh://xxxxx.com/project.git'


Your answer

1 Answer

More Devops discussions

Learn & Explore

Free tutorials and interview questions from industry experts — learn the skill, then get ready to prove it.

Latest DevOps Blogs

Guides, tips and career advice on DevOps from JanBask experts.