I'm using the below given commands for push data to heroku app.
git clone https://git.heroku.com/bigpro.git
cd bigpro
git add .
git commit . -m "my test on commit"
git push heroku master
When I used git push heroku master
I got something like this..
fatal: 'heroku' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Then I gave heroku open
command, I got an error which is
▸ ENOTFOUND: getaddrinfo ENOTFOUND api.heroku.com api.heroku.com:443
When I got the above error I tried to change commands on terminal by using heroku git:clone -a bigpro
and after made my changes, I gave git push heroku master
,I got an error
remote: ! Push rejected to bigpro. remote: To git.heroku.com/bigpro.git !
[remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to 'git.heroku.com/bigpro.git';
First, install the heroku toolbelt, and then type heroku login
to setup your account properly.
Next, type heroku git:clone -a myapp
where myapp
is the name of your application in Heroku. This will pull the repository and setup the remotes correctly for you.
Next, make your changes as usual.
Then you can do git push heroku master
This happened to me after I cloned from heroku a second copy of my files. Suddenly git push heroku master
wouldn't work and I'd get the same error as you. But when I tried git push origin master
, it worked fine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With