Ruby and Rails for womens

30
railsgirls.com/belem @luizsanxes Ruby and Rails for womens

description

Palestra realizada no Rails Girls Belém no dia 10 de Novembro de 2012

Transcript of Ruby and Rails for womens

Page 1: Ruby and Rails for womens

railsgirls.com/belem

@luizsanxes

Ruby and Rails for womens

Page 2: Ruby and Rails for womens

Malala Yusafzai

Page 3: Ruby and Rails for womens

programming languages

Page 4: Ruby and Rails for womens
Page 5: Ruby and Rails for womens

synchronous and asynchronous

Page 6: Ruby and Rails for womens

think different

Page 7: Ruby and Rails for womens

Ada Lovelace

Page 8: Ruby and Rails for womens

Ruby language

1995, Japan, Yukihiro "Matz" Matsumoto.

Interpreted, object-oriented and people.

Inspired by: Python, Perl, Smalltalk, Eiffel, Ada and Lisp.

Page 9: Ruby and Rails for womens

result.rb

$ ruby result.rb

Jully's code is 100% complete

Page 10: Ruby and Rails for womens

duck_typing.rb

$ ruby duck_typing.rb

9grapes and apples; grapes and apples;

Page 11: Ruby and Rails for womens

object

Page 12: Ruby and Rails for womens

class

Page 13: Ruby and Rails for womens

fruit.rb

$ ruby fruit.rb

Benefits of banana: acts on the vision, skin and mucous

Page 14: Ruby and Rails for womens

Interactive Ruby Shell

Page 15: Ruby and Rails for womens

Ruby Gems

gem install rails

gem list

gem uninstall haml

Page 16: Ruby and Rails for womens

web applications

Page 17: Ruby and Rails for womens

Ruby on Rails

2004, EUA, David Heinemeier Hansson.

Convention over Configuration

Don't Repeat Yourself

Model-View-Controller

Page 18: Ruby and Rails for womens

meta framework

railties

Web LayerActionController

Tests/SpecsTest::UnitORM

ActiveRecord

TemplatingErbHTTP Client

ActiveResource

Web ServerMongrel

slideshare.net/adamwiggins/rails-metal-rack-and-sinatra

Page 19: Ruby and Rails for womens

sites oriented database

CreateReadUpdateDelete

Page 20: Ruby and Rails for womens

Model, View and Controller

Page 21: Ruby and Rails for womens

creating a project

$ rails new market

$ cd market

Page 22: Ruby and Rails for womens

creating a crud

$ rails generate scaffold product name:string value:decimal unit:string

Page 23: Ruby and Rails for womens

Model

Page 24: Ruby and Rails for womens

View

Page 25: Ruby and Rails for womens

Controller

Page 26: Ruby and Rails for womens

creating a data structure

$ rake db:create

$ rake db:migrate

Page 27: Ruby and Rails for womens

executing the application

$ rails server

Page 28: Ruby and Rails for womens

show me the code

Page 29: Ruby and Rails for womens

ReferencesPortuguese> aprendaaprogramar.rubyonrails.pro.br> eustaquiorangel.com/tutorial-ruby> why.nomedojogo.com> caelum.com.br/apostila-ruby-on-rails

English> sapphiresteel.com/The-Book-Of-Ruby> guides.rubyonrails.org> github.com/bryanbibat/rails-3_0-tutorial

Page 30: Ruby and Rails for womens

thanks

@guru_pa

@tasafo