MEANJS - Add Git source control and deploy to Heroku

8 years ago

Open a Terminal from WebStorm and initialize git

git init

Add all files to Git.

git add -A

Commit files to Git.

git commit -m ‘first commit’

Add Heroku as a remote repository. You can get the Git URL, by clicking on your app from the Heroku dashboard, clicking settings, and looking under Info.

git remote add meanjs-heroku git@heroku.com:meanjs.git

Push to Heroku. (Note: This can take a few minutes.)

git push meanjs07-heroku master

Open the app by clicking on it from the Heroku dashboard or typing the following:

heroku open

If you need to troubleshoot Heroku, you can look at the logs by running the following command. Alternatively, Heroku has several helpful Add-ons that can be used for logging.

heroku logs
Discuss on Twitter