heroku basics

Create an application on heroku

$ heroku create --stack cedar
$ git push heroku master

This will create an auto-generated name. You can rename it to what you want.

$ heroku rename andrewchaarubydemoapp

Then you can run db:migrate to create tables.

$ heroku run rake db:migrate

You can check heroku logs, in case of any error

$ heroku logs

rake basics

Rake is ruby make, a make-like language in ruby. make has been used to build code in linux & unit environment.

$ bundle exec rake db:migrate

This execute migrate db scripts. Use bundle exec, to run the version of rake in your gem file.

$ bundle exec rake -T db
$ bundle exec rake -T
You can see rake commands.