Permalink
Browse files

adding episode 338

  • Loading branch information...
ryanb committed Apr 5, 2012
1 parent a459674 commit aedd3c816e4cc2d47085da4d78db5b78077f6a20
Showing with 2,546 additions and 0 deletions.
  1. +24 −0 episode-338/README.md
  2. +15 −0 episode-338/blog-after/.gitignore
  3. +40 −0 episode-338/blog-after/Gemfile
  4. +119 −0 episode-338/blog-after/Gemfile.lock
  5. +261 −0 episode-338/blog-after/README.rdoc
  6. +7 −0 episode-338/blog-after/Rakefile
  7. BIN episode-338/blog-after/app/assets/images/rails.png
  8. +15 −0 episode-338/blog-after/app/assets/javascripts/application.js
  9. +3 −0 episode-338/blog-after/app/assets/javascripts/articles.js.coffee
  10. +105 −0 episode-338/blog-after/app/assets/stylesheets/application.css
  11. +3 −0 episode-338/blog-after/app/assets/stylesheets/articles.css.scss
  12. +14 −0 episode-338/blog-after/app/controllers/application_controller.rb
  13. +41 −0 episode-338/blog-after/app/controllers/articles_controller.rb
  14. +2 −0 episode-338/blog-after/app/helpers/application_helper.rb
  15. +2 −0 episode-338/blog-after/app/helpers/articles_helper.rb
  16. 0 episode-338/blog-after/app/mailers/.gitkeep
  17. 0 episode-338/blog-after/app/models/.gitkeep
  18. +3 −0 episode-338/blog-after/app/models/article.rb
  19. +27 −0 episode-338/blog-after/app/views/articles/_form.html.erb
  20. +6 −0 episode-338/blog-after/app/views/articles/edit.html.erb
  21. +11 −0 episode-338/blog-after/app/views/articles/index.html.erb
  22. +5 −0 episode-338/blog-after/app/views/articles/new.html.erb
  23. +10 −0 episode-338/blog-after/app/views/articles/show.html.erb
  24. +22 −0 episode-338/blog-after/app/views/layouts/application.html.erb
  25. +4 −0 episode-338/blog-after/config.ru
  26. +61 −0 episode-338/blog-after/config/application.rb
  27. +6 −0 episode-338/blog-after/config/boot.rb
  28. +25 −0 episode-338/blog-after/config/database.yml
  29. +5 −0 episode-338/blog-after/config/environment.rb
  30. +37 −0 episode-338/blog-after/config/environments/development.rb
  31. +67 −0 episode-338/blog-after/config/environments/production.rb
  32. +37 −0 episode-338/blog-after/config/environments/test.rb
  33. +7 −0 episode-338/blog-after/config/initializers/backtrace_silencers.rb
  34. +15 −0 episode-338/blog-after/config/initializers/inflections.rb
  35. +5 −0 episode-338/blog-after/config/initializers/mime_types.rb
  36. +7 −0 episode-338/blog-after/config/initializers/secret_token.rb
  37. +8 −0 episode-338/blog-after/config/initializers/session_store.rb
  38. +14 −0 episode-338/blog-after/config/initializers/wrap_parameters.rb
  39. +7 −0 episode-338/blog-after/config/locales/en.yml
  40. +4 −0 episode-338/blog-after/config/locales/wk.yml
  41. +8 −0 episode-338/blog-after/config/routes.rb
  42. +1 −0 episode-338/blog-after/cookbooks
  43. +11 −0 episode-338/blog-after/db/migrate/20120402204955_create_articles.rb
  44. +14 −0 episode-338/blog-after/db/migrate/20120402221331_create_article_translations.rb
  45. +36 −0 episode-338/blog-after/db/schema.rb
  46. +5 −0 episode-338/blog-after/db/seeds.rb
  47. +2 −0 episode-338/blog-after/doc/README_FOR_APP
  48. 0 episode-338/blog-after/lib/assets/.gitkeep
  49. 0 episode-338/blog-after/lib/tasks/.gitkeep
  50. 0 episode-338/blog-after/log/.gitkeep
  51. +26 −0 episode-338/blog-after/public/404.html
  52. +26 −0 episode-338/blog-after/public/422.html
  53. +25 −0 episode-338/blog-after/public/500.html
  54. 0 episode-338/blog-after/public/favicon.ico
  55. +5 −0 episode-338/blog-after/public/robots.txt
  56. +6 −0 episode-338/blog-after/script/rails
  57. 0 episode-338/blog-after/test/fixtures/.gitkeep
  58. +11 −0 episode-338/blog-after/test/fixtures/articles.yml
  59. 0 episode-338/blog-after/test/functional/.gitkeep
  60. +49 −0 episode-338/blog-after/test/functional/articles_controller_test.rb
  61. 0 episode-338/blog-after/test/integration/.gitkeep
  62. +12 −0 episode-338/blog-after/test/performance/browsing_test.rb
  63. +13 −0 episode-338/blog-after/test/test_helper.rb
  64. 0 episode-338/blog-after/test/unit/.gitkeep
  65. +7 −0 episode-338/blog-after/test/unit/article_test.rb
  66. +4 −0 episode-338/blog-after/test/unit/helpers/articles_helper_test.rb
  67. 0 episode-338/blog-after/vendor/assets/javascripts/.gitkeep
  68. 0 episode-338/blog-after/vendor/assets/stylesheets/.gitkeep
  69. 0 episode-338/blog-after/vendor/plugins/.gitkeep
  70. +15 −0 episode-338/blog-before/.gitignore
  71. +38 −0 episode-338/blog-before/Gemfile
  72. +111 −0 episode-338/blog-before/Gemfile.lock
  73. +261 −0 episode-338/blog-before/README.rdoc
  74. +7 −0 episode-338/blog-before/Rakefile
  75. BIN episode-338/blog-before/app/assets/images/rails.png
  76. +15 −0 episode-338/blog-before/app/assets/javascripts/application.js
  77. +3 −0 episode-338/blog-before/app/assets/javascripts/articles.js.coffee
  78. +105 −0 episode-338/blog-before/app/assets/stylesheets/application.css
  79. +3 −0 episode-338/blog-before/app/assets/stylesheets/articles.css.scss
  80. +14 −0 episode-338/blog-before/app/controllers/application_controller.rb
  81. +41 −0 episode-338/blog-before/app/controllers/articles_controller.rb
  82. +2 −0 episode-338/blog-before/app/helpers/application_helper.rb
  83. +2 −0 episode-338/blog-before/app/helpers/articles_helper.rb
  84. 0 episode-338/blog-before/app/mailers/.gitkeep
  85. 0 episode-338/blog-before/app/models/.gitkeep
  86. +2 −0 episode-338/blog-before/app/models/article.rb
  87. +27 −0 episode-338/blog-before/app/views/articles/_form.html.erb
  88. +6 −0 episode-338/blog-before/app/views/articles/edit.html.erb
  89. +11 −0 episode-338/blog-before/app/views/articles/index.html.erb
  90. +5 −0 episode-338/blog-before/app/views/articles/new.html.erb
  91. +10 −0 episode-338/blog-before/app/views/articles/show.html.erb
  92. +22 −0 episode-338/blog-before/app/views/layouts/application.html.erb
  93. +4 −0 episode-338/blog-before/config.ru
  94. +59 −0 episode-338/blog-before/config/application.rb
  95. +6 −0 episode-338/blog-before/config/boot.rb
  96. +25 −0 episode-338/blog-before/config/database.yml
  97. +5 −0 episode-338/blog-before/config/environment.rb
  98. +37 −0 episode-338/blog-before/config/environments/development.rb
  99. +67 −0 episode-338/blog-before/config/environments/production.rb
  100. +37 −0 episode-338/blog-before/config/environments/test.rb
  101. +7 −0 episode-338/blog-before/config/initializers/backtrace_silencers.rb
  102. +15 −0 episode-338/blog-before/config/initializers/inflections.rb
  103. +5 −0 episode-338/blog-before/config/initializers/mime_types.rb
  104. +7 −0 episode-338/blog-before/config/initializers/secret_token.rb
  105. +8 −0 episode-338/blog-before/config/initializers/session_store.rb
  106. +14 −0 episode-338/blog-before/config/initializers/wrap_parameters.rb
  107. +7 −0 episode-338/blog-before/config/locales/en.yml
  108. +4 −0 episode-338/blog-before/config/locales/wk.yml
  109. +8 −0 episode-338/blog-before/config/routes.rb
  110. +11 −0 episode-338/blog-before/db/migrate/20120402204955_create_articles.rb
  111. +24 −0 episode-338/blog-before/db/schema.rb
  112. +5 −0 episode-338/blog-before/db/seeds.rb
  113. +2 −0 episode-338/blog-before/doc/README_FOR_APP
  114. 0 episode-338/blog-before/lib/assets/.gitkeep
  115. 0 episode-338/blog-before/lib/tasks/.gitkeep
  116. 0 episode-338/blog-before/log/.gitkeep
  117. +26 −0 episode-338/blog-before/public/404.html
  118. +26 −0 episode-338/blog-before/public/422.html
  119. +25 −0 episode-338/blog-before/public/500.html
  120. 0 episode-338/blog-before/public/favicon.ico
  121. +5 −0 episode-338/blog-before/public/robots.txt
  122. +6 −0 episode-338/blog-before/script/rails
  123. 0 episode-338/blog-before/test/fixtures/.gitkeep
  124. +11 −0 episode-338/blog-before/test/fixtures/articles.yml
  125. 0 episode-338/blog-before/test/functional/.gitkeep
  126. +49 −0 episode-338/blog-before/test/functional/articles_controller_test.rb
  127. 0 episode-338/blog-before/test/integration/.gitkeep
  128. +12 −0 episode-338/blog-before/test/performance/browsing_test.rb
  129. +13 −0 episode-338/blog-before/test/test_helper.rb
  130. 0 episode-338/blog-before/test/unit/.gitkeep
  131. +7 −0 episode-338/blog-before/test/unit/article_test.rb
  132. +4 −0 episode-338/blog-before/test/unit/helpers/articles_helper_test.rb
  133. 0 episode-338/blog-before/vendor/assets/javascripts/.gitkeep
  134. 0 episode-338/blog-before/vendor/assets/stylesheets/.gitkeep
  135. 0 episode-338/blog-before/vendor/plugins/.gitkeep
View
@@ -0,0 +1,24 @@
+# RailsCasts Episode #338: Globalize3
+
+http://railscasts.com/episodes/338-globalize3
+
+Requires Ruby 1.9.2 or higher.
+
+
+### Commands used in this episode
+
+```
+rails g migration create_article_translations
+rake db:migrate
+rails c
+```
+
+### Commands used in rails console
+
+```ruby
+I18n.locale
+Article.first.name
+I18n.locale = :wk
+Article.first.update_attribute(:name, "Ahhyya")
+I18n.locale = :en
+```
@@ -0,0 +1,15 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+# Ignore bundler config
+/.bundle
+
+# Ignore the default SQLite database.
+/db/*.sqlite3
+
+# Ignore all logfiles and tempfiles.
+/log/*.log
+/tmp
@@ -0,0 +1,40 @@
+source 'https://rubygems.org'
+
+gem 'rails', '3.2.2'
+
+# Bundle edge Rails instead:
+# gem 'rails', :git => 'git://github.com/rails/rails.git'
+
+gem 'sqlite3'
+
+
+# Gems used only for assets and not required
+# in production environments by default.
+group :assets do
+ gem 'sass-rails', '~> 3.2.3'
+ gem 'coffee-rails', '~> 3.2.1'
+
+ # See https://github.com/sstephenson/execjs#readme for more supported runtimes
+ # gem 'therubyracer'
+
+ gem 'uglifier', '>= 1.0.3'
+end
+
+gem 'jquery-rails'
+
+# To use ActiveModel has_secure_password
+# gem 'bcrypt-ruby', '~> 3.0.0'
+
+# To use Jbuilder templates for JSON
+# gem 'jbuilder'
+
+# Use unicorn as the app server
+# gem 'unicorn'
+
+# Deploy with Capistrano
+# gem 'capistrano'
+
+# To use debugger
+# gem 'ruby-debug19', :require => 'ruby-debug'
+
+gem 'globalize3'
@@ -0,0 +1,119 @@
+GEM
+ remote: https://rubygems.org/
+ specs:
+ actionmailer (3.2.2)
+ actionpack (= 3.2.2)
+ mail (~> 2.4.0)
+ actionpack (3.2.2)
+ activemodel (= 3.2.2)
+ activesupport (= 3.2.2)
+ builder (~> 3.0.0)
+ erubis (~> 2.7.0)
+ journey (~> 1.0.1)
+ rack (~> 1.4.0)
+ rack-cache (~> 1.1)
+ rack-test (~> 0.6.1)
+ sprockets (~> 2.1.2)
+ activemodel (3.2.2)
+ activesupport (= 3.2.2)
+ builder (~> 3.0.0)
+ activerecord (3.2.2)
+ activemodel (= 3.2.2)
+ activesupport (= 3.2.2)
+ arel (~> 3.0.2)
+ tzinfo (~> 0.3.29)
+ activeresource (3.2.2)
+ activemodel (= 3.2.2)
+ activesupport (= 3.2.2)
+ activesupport (3.2.2)
+ i18n (~> 0.6)
+ multi_json (~> 1.0)
+ arel (3.0.2)
+ builder (3.0.0)
+ coffee-rails (3.2.2)
+ coffee-script (>= 2.2.0)
+ railties (~> 3.2.0)
+ coffee-script (2.2.0)
+ coffee-script-source
+ execjs
+ coffee-script-source (1.2.0)
+ erubis (2.7.0)
+ execjs (1.3.0)
+ multi_json (~> 1.0)
+ globalize3 (0.2.0)
+ activemodel (>= 3.0.0)
+ activerecord (>= 3.0.0)
+ paper_trail (~> 2)
+ hike (1.2.1)
+ i18n (0.6.0)
+ journey (1.0.3)
+ jquery-rails (2.0.1)
+ railties (>= 3.2.0, < 5.0)
+ thor (~> 0.14)
+ json (1.6.6)
+ mail (2.4.4)
+ i18n (>= 0.4.0)
+ mime-types (~> 1.16)
+ treetop (~> 1.4.8)
+ mime-types (1.18)
+ multi_json (1.2.0)
+ paper_trail (2.6.3)
+ activerecord (~> 3.0)
+ railties (~> 3.0)
+ polyglot (0.3.3)
+ rack (1.4.1)
+ rack-cache (1.2)
+ rack (>= 0.4)
+ rack-ssl (1.3.2)
+ rack
+ rack-test (0.6.1)
+ rack (>= 1.0)
+ rails (3.2.2)
+ actionmailer (= 3.2.2)
+ actionpack (= 3.2.2)
+ activerecord (= 3.2.2)
+ activeresource (= 3.2.2)
+ activesupport (= 3.2.2)
+ bundler (~> 1.0)
+ railties (= 3.2.2)
+ railties (3.2.2)
+ actionpack (= 3.2.2)
+ activesupport (= 3.2.2)
+ rack-ssl (~> 1.3.2)
+ rake (>= 0.8.7)
+ rdoc (~> 3.4)
+ thor (~> 0.14.6)
+ rake (0.9.2.2)
+ rdoc (3.12)
+ json (~> 1.4)
+ sass (3.1.15)
+ sass-rails (3.2.5)
+ railties (~> 3.2.0)
+ sass (>= 3.1.10)
+ tilt (~> 1.3)
+ sprockets (2.1.2)
+ hike (~> 1.2)
+ rack (~> 1.0)
+ tilt (~> 1.1, != 1.3.0)
+ sqlite3 (1.3.5)
+ thor (0.14.6)
+ tilt (1.3.3)
+ treetop (1.4.10)
+ polyglot
+ polyglot (>= 0.3.1)
+ tzinfo (0.3.32)
+ uglifier (1.2.4)
+ execjs (>= 0.3.0)
+ multi_json (>= 1.0.2)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ coffee-rails (~> 3.2.1)
+ globalize3
+ jquery-rails
+ rails (= 3.2.2)
+ sass-rails (~> 3.2.3)
+ sqlite3
+ uglifier (>= 1.0.3)
Oops, something went wrong.

0 comments on commit aedd3c8

Please sign in to comment.