git push heroku master says “Everything up-to-date”, but the app is not current

前端 未结 13 1374
孤独总比滥情好
孤独总比滥情好 2020-12-02 09:00

I have an app on Heroku that is running old code. I\'ve made a small change and committed the change. I then ran

git push heroku master

I

相关标签:
13条回答
  • 2020-12-02 09:13

    Try:

    heroku status

    This returned the following, which confirmed that the problem was with the heroku API (and not with my app!):

    "The API is experiencing delays. This may result in delays with adding new domains, new releases, and other such actions. Currently, engineers are investigating the issue."

    0 讨论(0)
  • 2020-12-02 09:19

    When you run git push heroku master, git is assuming that you are pushing from master, so if you changes are in other branch, you will try to push your master branch without changes.

    You have two options

    1.Merge your changes with master and push them.

    Commit your changes in your actual branch, then merge them with master

    git commit -a - m "your messages"
    git checkout master
    git merge your_feature_branch
    git push heroku master
    

    2.Push your changes from your actual branch

    git push heroku your_feature_branch:master
    
    0 讨论(0)
  • 2020-12-02 09:24

    I'm willing to bet you've forgotten to run git add . followed by git commit -m 'xyz'?

    0 讨论(0)
  • 2020-12-02 09:25

    Kindly confirm your current branch is master.

     git branch 
    

    If the pointer is not pointing the master, then check out to master branch

    git checkout master
    

    Commit your changes and try to push to heroku

    git commit -am "xxxyyzzz"    
    git push heroku master
    
    0 讨论(0)
  • 2020-12-02 09:25

    I had a similar issue and by no means my changes were visible on heroku. To reconfirm myself I even took a clone from heroku and it was obviously up to date.

    I could resolve my issue only by following this approach:

    Step 1: Make a new branch from master

    git checkout -b new_branch
    

    Step 2: Just add a comment in any file to make a new commit and then:

    git add .
    git commit -m "Just a test commit to push new branch to heroku"
    

    Step 3: Push the new branch to heroku.

    git push heroku new_branch:master
    heroku restart
    

    You could now see your changes successfully on heroku.

    0 讨论(0)
  • 2020-12-02 09:25

    My executable name had changed but I forgot to change the name in my Procfile. So while all the files were updating correctly in heroku, the same old executable was running. I used heroku local from the command line to help track that issue down.

    0 讨论(0)
提交回复
热议问题