Introduction To Rails

2,710 views
2,643 views

Published on

Introduction to the Ruby programming language the the Ruby on Rails framework.

Published in: Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
2,710
On SlideShare
0
From Embeds
0
Number of Embeds
52
Actions
Shares
0
Downloads
89
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide

Introduction To Rails

  1. 1. Introduction to Ruby on Rails “Web development that doesn’t hurt.” Eric J. Gruber
  2. 2. About Ruby  Released in 1995  Open source  Available for: – Windows – Mac OS X – Linux  Ruby home: http://www.ruby-lang.org/en/  Try Ruby!: http://tryruby.hobix.com
  3. 3. About Ruby  Dynamic language, like PHP  Clean syntax, natural wording, easy to read – C#: public class Hello1 { public static void Main() { System.Console.WriteLine("Hello, World!"); } } – ASP.NET: <% HelloWorldLabel.Text = “Hello, World!”; %> – PHP: <?php print “Hello, World!”; ?> – Ruby: puts “Hello, World!”
  4. 4. About Ruby  Everything is an object in Ruby Images from the book Simply Rails 2 by Patrick Lenz
  5. 5. Ruby meet Rails
  6. 6. Who uses Ruby on Rails?
  7. 7. Other success stories  From ruby-lang.org: – http://ruby-lang.org/en/documentation/success-stories  From rubyonrails.org: – http://rubyonrails.org/applications
  8. 8. What is Ruby on Rails?  Web framework, powered by Ruby, extracted from the highly successful project management web application, Basecamp. http://basecamphq.com
  9. 9. Framework? What’s that?  A framework is a basic conceptual structure used to solve or address complex issues. This very broad definition has allowed the term to be used as a buzzword, especially in a software context. – http://en.wikipedia.org/wiki/Framework
  10. 10. In other words …  … it’s like magic!
  11. 11. Why should I care? Do more with fewer resources  Easy validations  Works well with Ajax  Better separation of  Good amount of code resources available to – HTML, CSS (views) learn – Database, business  Easy for designers, fun logic (models) for programmers – User interface,  Database agnostic application logic (controllers)
  12. 12. Everything is in its right place  Embrace your constraints  Don’t Repeat Yourself  Every Rails app has the same file structure Image from the book RailsSpace by Michael Hartl and Aurelius Prochazka
  13. 13. Demo
  14. 14. How to get started  Use the Ruby on Rails download page: – http://rubyonrails.org/download, or …  Windows users can download InstantRails for the total package: – http://instantrails.rubyforge.org/wiki/wiki.pl  Mac users can download Locomotive for a quick test run (might need to be updated): – http://sourceforge.net/projects/locomotive/  Linux users can … it depends on your distro  Sign up free at http://herokugarden.com
  15. 15. Recommended Ruby reading  Learn to Program, 2nd Edition Great for beginners – PragProg.com  Programming Ruby 1.9 – PragProg.com A lot more advanced
  16. 16. Recommended Rails reading  Simply Rails 2.0 – Sitepoint.com Great for beginners  Agile Web Development with Rails – PragProg.com A little bit more advanced
  17. 17. Resources  Ruby on Rails: Talk (Google Group) – http://groups.google.com/group/rubyonrails-talk  Railscasts (free Ruby on Rails screencasts) – http://railscasts.com  Peep Code (paid Rails-related screencasts) – http://peepcode.com  Phusion Passenger (easy deployment module) – http://www.modrails.com  Agile Web Development (plugin central) – http://agilewebdevelopment.com/
  18. 18. Hosting  http://slicehost.com  http://railsplayground.com  http://www.site5.com  http://dreamhost.com  http://hostgator.com  Web Hosting Services Which Support Ruby on (from Rails Wiki)
  19. 19. Questions?

×