0

I encounter this weird situation...

I have a commit pushed to github...

then the commit disappears from git status...

how can I commit that same file to heroku?

any help would be appreciated.

asked Mar 19, 2020 at 20:49

1 Answer 1

2

First add the heroku remote to your local git.

git remote add <your heroku git url>

replace <your heroku git url> with your actual heroku git url, you can find it from settings tab of on your heroku dashboard, it looks something like this: https://git.heroku.com/app-name.git

once heroku remote is added, you can simply push the latest commit by:

git push heroku master

replace master with whatever branch you want to push, normally it is master

answered Mar 19, 2020 at 21:19
Sign up to request clarification or add additional context in comments.

2 Comments

thanks, will this push to Github and to Heroku at the same time?
No this will only push to heroku.. if you want to push to github too, you can run 'git push origin master' separately

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.