How to view remote Git revision on Heroku

前端 未结 6 1002
感情败类
感情败类 2020-12-12 11:55

For deploying to Heroku, I use git push heroku master. But how do I see which revision I pushed up to heroku? (I\'m often in doubt if I pushed the recent versio

6条回答
  •  半阙折子戏
    2020-12-12 12:36

    if you've run into the situation, like i just did, where a co-worker rolled back your heroku app to a release that doesn't show in heroku releases because they only keep track of 2 releases... the checkout of heroku/master method won't help, because HEAD is not what is deployed anymore.

    the undocumented to the rescue:

    $ heroku console "ENV['COMMIT_HASH']"
    "12abcdef"
    

提交回复
热议问题