How to resolve error failed to push some refs to git?

Share Me
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

Today now in post i would like to show you how to resolve error failed to push some refs to git. When I was fetch this error on that time i was working on my php project and when i need to add that project on my gitlab account. So at first i was create a repository on my gitlab account and then clone that repo. But when i was try to push first time my projects i was found the following error:

error failed to push some refs to https://[email protected]/infotech/mycollege.git

Then I was try many to solve the bellow issue, but i can’t found any proper solution now at last i was try my own to git add as like this way :

git add -A
git commit -m "setup project"
git push origin master....

Read Also : How to convert Object into Array in PHP?

Thanks for read. I hope it help you. For more you can follow us on facebook.

About code chef

My name is Shahriar sagor. I'm a developer. I live in Bangladesh and I love to write tutorials and tips that will help to other Developer's. I am a big fan of PHP, Javascript, JQuery, Laravel, Codeigniter, VueJS, AngularJS and Bootstrap from the early stage.

View all posts by code chef →