Home
> Open Source Development > Your first Ruby on Rails Application
Your first Ruby on Rails Application
The following is an example of how to create a simple ruby on rails application, on a Ubuntu development machine, push it to GitHub source control, and to Heroku for cloud hosting.
|
Here is the build of tools on my virtual machine:
- Ubuntu 12.04 LTS
- Git v 1.7.9.5
- Rails v 3.2.3
- Sublime Text 2 Build 2195
Part 1
mkdir code
rails new app1
cd app1
rails g scaffold post title text:text
rake db:migrate
Part 2
subl Gemfile
[add the following to file]
group :production do
gem 'pg'
end
group :development, :test do
gem 'sqlite3'
end
gem install pg
bundle install
[create 'app1' repository at github.com]
git init
git add .
git commit -m "baseline"
git remote add origin git@github.com:stevenfowler/app1.git
git push -u origin master
Part 3
heroku create -s cedar
git push heroku master
heroku run rake db:migrate
heroku open
Categories: Open Source Development
awesome tutorial!
keep up the good work.
Great tutorial. Couldn’t find your other rails tutorials, however would be thankful if you could send me their links.
i love you for making this – i know i am a couple years out but i had a great time running through this tutorial 🙂
Thanks
Is there a tutorial before this one on how to set up the environment for rails?
There are other YOUTUBE videos out there for basic Linux installations.
Steven, I’m new to Ruby and like your teaching style. Will you be making any other Ruby tutorials in the future?
Steven
Thanks for your post on rails, git And heroku.
How did you install virtual box and do you use vagrant? I have trouble getting my machine working on mac.
Where are your next videos on styling of the App you built?
Steve
Thanks.
Where are your next videos????
hi
when I do Subl Gemfile
this happens:
No command ‘subl’ found, did you mean:
Command ‘subs’ from package ‘libsubtitles-perl’ (universe)
Command ‘publ’ from package ‘atfs’ (universe)
subl: command not found
what should i do???????????