error: src refspec master does not match any.
error: failed to push some refs to '[email protected]:evening-scrubland-91960.git'
Where [email protected]:evening-scrubland-91960.git
is the name of my app.
If it helps, I'm using this website as a tutorial:
https://devcenter.heroku.com/articles/getting-started-with-python#deploy-the-app
I've also used the following suggestions from the below website:
I want make push and get error: src refspec master does not match any
You may also get the above error, if you are you still using "master" instead of "main".
Instead of: "git push heroku master"
Try: "git push heroku main"
–
–
The log tells you everything:
src refspec master does not match any
means that there is nothing committed on master branch yet.
Be sure, that you have staged your changes using the git add command and committed them using the git commit command before pushing them to the remote.
–
Resolving possible errors, such as: Error: spawn cmd ENOENT, Code: ENOENT,H10 no modulError
Go to the heroku site, create a new application. Done this, open command prompt administrator mode on your pc, just click with right button. It will open the command screen, in front of this, activate your k39 or k3X.com
activate k39
After:
heroku login
Validate the token on the heroku page, just click. No cmd change to project director.
cd C:\Users\Lancaster\PycharmProjects\
Put the address where the project is on your pc, do not put the example. Once that's done, the first time you're submitting the project, do:
git init
git config --global user.email "email@email"
git config --global user.name "nameapp"
heroku git:remote -a nameapp
Now add these commands, always when updating your page.
git add .
git commit -am "make it better"
git push heroku master
If you have a secondary page that is, you created more than one app or it is not the root or give an error in the final command, claiming not to be the master.
git push heroku
After that, the submission will occur normally.
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.