I got the following when I try to git push to heroku
fatal: Not a git repository (or any of the parent directories): .git
I try to follow
Make sure you have followed all the steps in the Installation and setup section of the Rails Tutorial book.
The error message you are getting is indicating that you have missed the git init
step.
Have you created a git repository? Create it using git init
and then commit some files.
http://git-scm.com/book/en/Git-Basics-Getting-a-Git-Repository
you aren't on a git repository directory.
type pwd
and make sure it's where you think you should be. chances are you are in ~/
or something just before the directory you think you are in.
update sep 2020
first, you have git repo required to create a heroku app
git init
git add .
git commit -m "initial commit"
heroku create
git push heroku master
how your code uploading to Heroku
This error comes because you are trying to push the changes from a non-cloned working copy of your git repository. have you initialized git repo on the dir that you are working?? if not so initialize git repo by using git init
and then either do a git clone
or add a remote by using git remote add origin git@github.com:repourl.git
for more detail refer this