Push origin master error on new repository
I was having the same issue and then smacked myself in the head because I hadn't actually added my project files.
git add -A
git commit -am "message"
git push origin master
The error message leads to the conclusion that you do not have a master
branch in your local repository. Either push your main development branch (git push origin my-local-master:master
which will rename it to master
on github) or make a commit first. You can not push a completely empty repository.
I had the same issue. I deleted the .git folder then followed the following commands
$ git init
$ git add .
$ git remote add origin [email protected]:project/project.git
$ git commit -m "Initial version"
$ git push origin master
I have same issue . it's solved my problem . İf you init your git . you have to do on Terminal
1) git add .
2)git commit -m "first commit"
For send to bitbucket
3) git push -u origin --all # pushes up the repo and its refs for the first time