Friday, September 1, 2017
Scripting the Heroku Push
Scripting the Heroku Push
This tip falls under the KISS principle. I recently started using the Heroku service to run some Rails websites. After making changes and committing them to your local Git repository, those changes are pushed to Heroku using the command git push heroku master
. Since Im likely to forget and since its four words I created a file called script/push
with that command. Here are the steps.
- Create a file called script/push with one line:
git push heroku master
. - Run
chmod +x script/push
- Run
git add script/push
. - Run
git commit -m "scripting the Heroku push"
. - Run
script/push
.
Thats it. Just script/push
whenever you need to deploy.
download file now
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.