0

Hi guys I have a question. When I push to Git I do:

git add .
git commit -m "My message"
git push origin master

and right after that if I repeat the previous steps to push to Heroku I get:

nothing to commit, working directory clean

but if I run:

git push heroku master

it star doing a bunch of things like Installing dependencies, etc. that are unnecessary.

What's the right way to do it? Thanks.

asked Aug 29, 2014 at 21:00
0

2 Answers 2

1

Only push to heroku master when you want to deploy your code to Heroku. Otherwise, simply push your code to origin. Once you are ready to deploy again, push to heroku.

answered Aug 29, 2014 at 21:03
Sign up to request clarification or add additional context in comments.

Comments

0
git add .
git commit -m "My message"
git push origin master

The above commits your work and send it to git. To deploy your application (from git to heroku) you use the following:

git push heroku master

It will send the code in your git (branch master) to heroku.

answered Aug 29, 2014 at 21:05

Comments

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.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.