Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Introduction to Ruby on Rails
Search
Angel Avgerinos
March 19, 2013
Programming
210
3
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Introduction to Ruby on Rails
Presentation at University of Piraeus
Angel Avgerinos
March 19, 2013
More Decks by Angel Avgerinos
See All by Angel Avgerinos
Hacking our way to Geembo
eavgerinos
1
110
Other Decks in Programming
See All in Programming
go-spidermonkeyでAIエージェントのCode Modeを実装する
syumai
2
1.2k
<title><a id="</title>君はこのHTMLをパースできるか"></a></title> #雑LT_study
pizzacat83
0
180
レビュー履歴をAIに食わせて、 Compose移行を加速するs
shihochan
0
220
Jindong: Introducing Declarative Haptics in Compose Multiplatform
l2hyunwoo
0
130
Cloudflare is Agents
chimame
0
180
Go を使い始めて 2 ヶ月の学び / My first two months with Go
contour_gara
0
380
Press start. Python's next generation.
willingc
PRO
3
180
Webエンジニアなのにブラウザの仕組みがわからないので、Pythonで自作してみた
tatsuki12
4
1.1k
TSX の <Hoge<Fuga>> という構文に驚いた話 / tsx-type-argument-syntax
kanaru0928
0
240
【デモ】Kiroで体験する仕様駆動開発|設計からコーディングまでAIと進める開発フロー
cmkudo
0
400
異なる設計思想のフレームワークを経験して得た学び
amekuhideki
1
610
Go 1.27 における memory allocation の高速化
andpad
0
330
Featured
See All Featured
Amusing Abliteration
ianozsvald
1
260
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.3k
How to Ace a Technical Interview
jacobian
281
24k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
2
650
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
280
What's in a price? How to price your products and services
michaelherold
247
13k
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.4k
Why You Should Never Use an ORM
jnunemaker
PRO
61
10k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
3k
Scaling GitHub
holman
464
140k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
480
Leading Effective Engineering Teams in the AI Era
addyosmani
9
2.4k
Transcript
INTRODUCTION - to -
Angel Avgerinos Ruby on Rails & Java developer
RUBY A multi-paradigm general purpose language
Yukihiro Matsumoto (Matz) Creator of Ruby programming language (1995)
What Ruby is
OBJECT - ORIENTED Everything in Ruby is an object (instance
of a Class)
FUNCTIONAL Supports Lambdas and Procs
REFLECTIVE Ruby can modify the structure of an object at
runtime
IMPERATIVE Modules and Blocks
Why Ruby rocks
OPEN SOURCE https://github.com/ruby/ruby
READABLE AND SEXY No semicolons, no mandatory parentheses, method chaining.
TREND RIGHT NOW 2nd most popular language at Github.com
CHECK THIS OUT
class Calc # Creates getters and setters for
num1 and num2 attr_accessor :num1, :num2 def initialize(num1, num2) @num1 = num1 @num2 = num2 end def add #string interpolation puts "#{@num1 + @num2}" end end c = Calc.new(1,2) c.add
WHAT ABOUT LIBRARIES ?
Gem A package format for Ruby programs and libraries
The structure of a Gem
INSTALLING GEMS from RubyGems.org gem install gem_name
Let’s take it to the next level Just type...
gem install rails Now you have superpower
Ruby on Rails MVC framework to get you on the
Web
David Heinemeier Hansson (DHH) Creator of Ruby on Rails (2004)
and partner at 37signals
What Rails is
GEM Just a Gem with reusable code! No fancy installs!
OPEN SOURCE https://github.com/rails/rails
FRAMEWORK A Web application framework.
MVC Awesome pattern.
What Rails is NOT
What Rails is NOT A Programming language
AWESOMENESS MVC
MODEL VIEW CONTROLLER View Controller Model Database
MODEL
CONTROLLER
VIEW
STARTING A NEW RAILS PROJECT
rails new app_name TYPE...
RAILS APP STRUCTURE
/APP
/CONFIG
GEMFILE Where your life becomes easier
source 'https://rubygems.org' gem 'rails', '3.2.12' group :development, :test do
gem 'sqlite3' end group :assets do gem 'sass-‐rails', '~> 3.2.3' gem 'coffee-‐rails', '~> 3.2.1' gem 'uglifier', '>= 1.0.3' gem 'compass-‐rails' gem 'sassy-‐buttons' gem 'bootstrap-‐sass', '~> 2.3.0.1' gem 'font-‐awesome-‐sass-‐rails' end gem 'jquery-‐rails' gem 'omniauth-‐facebook' gem 'devise', '2.2.3' gem 'geocoder'
A GLIMPSE OF RAILS
SCAFFOLDING rails g scaffold User email:string
MIGRATION rake db:migrate
RAILS SERVER rails s
DONE!
HOW TO GET STARTED
tryruby.org codeschool.com codecademy.com railstutorial.org/book railscasts.com github.com RESOURCES
THANKS @eavgerinos
[email protected]