+ RUBY ON RAILS 3 Tutorial ををををををををを Chapter 11-13( ををを ) 2012/01/11
+
RUBY ON RAILS 3 Tutorial を日本語訳してみたChapter 11-13( 最終回 )
2012/01/11
+Ruby on Rails Tutorial とは
前に LT したときに紹介したサイト http://ruby.railstutorial.org/ruby-on-rails-tutorial-
book
2
+この Tutorial では…
Twitter( もどき ) を作っています
基本的な機能を備えるようにしている ユーザのプロフィールページ
フォロー・フォロワー
ツイートの Post
サインアップ・ログイン・ログアウト
等々
3
+今回が最終回
全 12 章だと思っていたら、 13 章になっていた
11 章・ 12 章初めは軽く触れるのみ、 12 章最後・ 13 章について今日は話します。
4
目次
Chapter1 Rails 導入からデプロイ
Chapter2 デモアプリ (scaffold 使用 )
Chapter3 Web アプリケーション
Chapter4 Rails 風 Ruby
Chapter5 スタイルを追加する
Chapter6 User Model と View その 1
Chapter7 User Model と View その 2
5
目次
Chapter8 ユーザ登録
Chapter9 ログイン・ログアウト
Chapter10 ユーザデータの更新・編集・追加
Chapter11 ミニブログ ( ツイート )
Chapter12 ユーザのフォロー
Chapter13 Rails3.1
6
+Chapter11 User microposts 章立て
11.1 Micropost モデル
11.2 micropost の表示
11.3 micropost の操作 ( 追加・削除・制限 )
7
+Chapter11 User microposts
ツイート投稿するための実装
テスト (RSpec) のコード バリデーション
8
+Chapter12 Following users 章立て
12.1 リレーション
12.2 フォロー・フォロワー表示
12.3 ステータスフィード
9
+Chapter12 Following users
フォロー・フォロワー関係の実装
DB のリレーション has_many
belongs_to
:through
10
+12.4.2 他の Rails 教材紹介
①Ruby on Rails Tutorial screencast( 有料 )(http://railstutorial.org/screencasts)
このチュートリアルに沿った動画本では表示できない、デモ等有り
11
+12.4.2 他の Rails 教材紹介
②Railscasts( 有料・無料 )
http://railscasts.com/
Rails の説明動画集
無料動画多数あり。動画によって有料会員の必要性有り。
テキスト化されている → ASCIIcasts(http://asciicasts.com/)
日本語訳版有り (http://ja.asciicasts.com/)
12
+12.4.2 他の Rails 教材紹介
③Scaling Rails( 無料 ) http://railslab.newrelic.com/scaling-rails
( 本 Tutorial では触れていない ) スケールやパフォーマンスについての勉強が出来る
作者的に、 Scout(https://scoutapp.com/) や New
Relic(http://www.newrelic.com/) 調べてみるのおすすめ
13
+12.4.2 他の Rails 教材紹介
③Ruby on Rails 系の本
本チュートリアル Chapter1
「 Beginning
Ruby 」 http://www.amazon.com/gp/product/1430223634
「 The Well-Grounded
Rubyist 」 http://www.amazon.com/gp/product/1933988
657
14
15
+12.4.2 他の Rails 教材紹介
(↓もっと Ruby を勉強するなら)「 The Ruby Way 」 http://www.amazon.com/gp/product/0672328844
(↓もっと Rails を勉強するなら)「 Rails 3 Way 」 http://www.amazon.com/gp/product/0321601661
16
17
+12.4.2 他の Rails 教材紹介
④PeepCode ( 有料 ) http://peepcode.com/
とても広い知識を付けられる
クオリティがたかいらしい
18
個人的には、 Rails for Zombies(http://railsforzombies.org/) おすすめ。無料で出来て、 screencast で勉強→クイズの流れRails 初学にすごくいいと思う。
+Chapter13 Rails3.1
Rails が 3.1 になって変わったところが多数Prototype.js→jQuery
Sass ・ CoffeeScript
等々
19
+13.1 Upgrading the sample app
Rails のバージョンを 3.1 に上げる
「 Helpful resources for upgrading to Rails 3.1 」 http://jasonrudolph.com/blog/2011/06/06/helpful-resources-for-
upgrading-to-rails-3-1/
「 How to upgrade a Rails application to version 3.1.0 」 http://davidjrice.co.uk/2011/05/25/how-to-
upgrade-a-rails-application-to-version-3-1-0.html
Tutorial では下の方を使う
20
+13.1.4 Major differences
public 以下にあった images 、 stylesheets 、javascripts が app/assets 以下に vendor/assets 以下にはライブラリを置く
JS ライブラリが Prototype から jQuery に変更
21
+
本の内容はここまで!
22
+Tutorial 全部を通して
Ruby の文法的基礎・ Rails のセットアップから Git の使いかた・テストの書き方(RSpec)
Twitter ぽい物
ができるようになります!
情報源にすべきサイト・本が載っている
23
+Ruby on Rails Tutorial に関して
分かりやすい英語で読みやすい Screencast を買うという手も
更新がちゃんとされている。割と新しい情報
ちょっと重いが、初心者 (~ 中級者 ?) 向け
24
+エピローグ
2011/9 から、思いつきで初めてはや 2012 年…
Hamamatsu.rb の場をお借りしてきました
試行錯誤うまくいかず、グダグダ感あふれる発表…
Hamamatsu.rb のおかげで読了できました!
25
26
ご清聴ありがとうございました!
長い間大変お世話になりました!
今月で参加はおそらく最後になると思います。海山は東京に飛んで行きます。またお会いする日まで!