<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>blog/app/controllers/roles_controller.rb</filename>
    </added>
    <added>
      <filename>blog/app/controllers/sessions_controller.rb</filename>
    </added>
    <added>
      <filename>blog/app/controllers/users_controller.rb</filename>
    </added>
    <added>
      <filename>blog/app/helpers/roles_helper.rb</filename>
    </added>
    <added>
      <filename>blog/app/helpers/sessions_helper.rb</filename>
    </added>
    <added>
      <filename>blog/app/helpers/users_helper.rb</filename>
    </added>
    <added>
      <filename>blog/app/models/role.rb</filename>
    </added>
    <added>
      <filename>blog/app/models/user.rb</filename>
    </added>
    <added>
      <filename>blog/app/views/layouts/roles.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/roles/edit.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/roles/index.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/roles/new.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/roles/show.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/sessions/new.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/users/_user_bar.html.erb</filename>
    </added>
    <added>
      <filename>blog/app/views/users/new.html.erb</filename>
    </added>
    <added>
      <filename>blog/config/initializers/new_defaults.rb</filename>
    </added>
    <added>
      <filename>blog/config/initializers/site_keys.rb</filename>
    </added>
    <added>
      <filename>blog/db/migrate/20080525223953_create_users.rb</filename>
    </added>
    <added>
      <filename>blog/db/migrate/20080525224000_add_role_table.rb</filename>
    </added>
    <added>
      <filename>blog/db/migrate/20080525224027_add_time_zone_to_user.rb</filename>
    </added>
    <added>
      <filename>blog/lib/authenticated_system.rb</filename>
    </added>
    <added>
      <filename>blog/lib/authenticated_test_helper.rb</filename>
    </added>
    <added>
      <filename>blog/public/stylesheets/scaffold.css</filename>
    </added>
    <added>
      <filename>blog/test/fixtures/roles.yml</filename>
    </added>
    <added>
      <filename>blog/test/fixtures/users.yml</filename>
    </added>
    <added>
      <filename>blog/test/functional/roles_controller_test.rb</filename>
    </added>
    <added>
      <filename>blog/test/functional/sessions_controller_test.rb</filename>
    </added>
    <added>
      <filename>blog/test/functional/users_controller_test.rb</filename>
    </added>
    <added>
      <filename>blog/test/unit/role_test.rb</filename>
    </added>
    <added>
      <filename>blog/test/unit/user_test.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/.gitignore</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/CHANGELOG</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/README</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/Rakefile</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/TODO</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/USAGE</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/authenticated_generator.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/lib/insert_routes.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/_model_partial.html.erb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/activation.html.erb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/authenticated_system.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/authenticated_test_helper.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/controller.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/helper.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/login.html.erb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/mailer.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/migration.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/model.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/model_controller.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/model_helper.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/model_helper_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/observer.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/signup.html.erb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/signup_notification.html.erb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/site_keys.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/controllers/access_control_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/controllers/authenticated_system_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/controllers/sessions_controller_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/controllers/users_controller_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/fixtures/users.yml</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/helpers/users_helper_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/spec/models/user_spec.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/rest_auth_stories.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/rest_auth_stories_helper.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/steps/ra_navigation_steps.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/steps/ra_resource_steps.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/steps/ra_response_steps.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/steps/user_steps.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/users/accounts.story</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/stories/users/sessions.story</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/test/functional_test.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/test/mailer_test.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/test/model_functional_test.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/generators/authenticated/templates/test/unit_test.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/init.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/install.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/authentication.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/authentication/by_cookie_token.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/authentication/by_password.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/authorization.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/authorization/stateful_roles.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/trustification.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/lib/trustification/email_validation.rb</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/AccessControl.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/Authentication.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/Authorization.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/RailsPlugins.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/SecurityFramework.graffle</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/SecurityFramework.png</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/SecurityPatterns.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/Tradeoffs.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/plugins/restful-authentication/notes/Trustification.txt</filename>
    </added>
    <added>
      <filename>blog/vendor/rails</filename>
    </added>
    <added>
      <filename>blog_remote/vendor/rails</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -3,7 +3,7 @@
 This mini Rails app is meant to just showcase the new features in Rails 2.x but it 
 should not be used as a reference for 'best practices'. 
 
-== AkitaOnRails.com - Rolling with Rails 2.0 - The First Full Tutorial
+== Dec 2007 - AkitaOnRails.com - Rolling with Rails 2.0 - The First Full Tutorial
 
 This is the source code for the first Rails 2.0 tutorial released on 
 Dec 12th 2007. There is a screencast available that shows it step by step:
@@ -15,5 +15,10 @@ And the written tutorial in 2 parts here:
 http://www.akitaonrails.com/2007/12/12/rolling-with-rails-2-0-the-first-full-tutorial
 http://www.akitaonrails.com/2007/12/12/rolling-with-rails-2-0-the-first-full-tutorial-part-2
 
-Follow the TAG 2.0 at Github for this.
+Follow the TAG &quot;for_2.0&quot; at Github.
 
+== May 2008 - AkitaOnRails.com - Rolling with Rails 2.1 - The First Full Tutorial
+
+This is the source code for the first Rails 2.1 tutorial released on May 25th, 2008. I will update this file with the tutorial link today.
+
+Follow the TAG &quot;for_2.1&quot; at Github.
\ No newline at end of file</diff>
      <filename>README</filename>
    </modified>
    <modified>
      <diff>@@ -7,4 +7,13 @@ class ApplicationController &lt; ActionController::Base
   # See ActionController::RequestForgeryProtection for details
   # Uncomment the :secret if you're not using the cookie session store
   protect_from_forgery # :secret =&gt; '64f9f5ea86204105f5052eb876bd5f61'
+
+  before_filter :set_timezone
+
+  private
+  def set_timezone
+    # current_user.time_zone #=&gt; 'London'
+    Time.zone = current_user.time_zone rescue nil
+  end
+
 end</diff>
      <filename>blog/app/controllers/application.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,3 +1,8 @@
 class Post &lt; ActiveRecord::Base
   has_many :comments
+
+  named_scope :empty_body, :conditions =&gt; &quot;(body = '' or body is null)&quot;
+  named_scope :this_week, :conditions =&gt; [&quot;created_at &gt; ?&quot;, 1.week.ago.to_s(:db)]
+  named_scope :recent, lambda { |*args| {:conditions =&gt; 
+	  [&quot;created_at &gt; ?&quot;, (args.first || 2.weeks.ago).to_s(:db)]} }
 end</diff>
      <filename>blog/app/models/post.rb</filename>
    </modified>
    <modified>
      <diff>@@ -24,9 +24,8 @@ module Rails
       File.exist?(&quot;#{RAILS_ROOT}/vendor/rails&quot;)
     end
 
-    # FIXME : Ruby 1.9
     def preinitialize
-      load(preinitializer_path) if File.exists?(preinitializer_path)
+      load(preinitializer_path) if File.exist?(preinitializer_path)
     end
 
     def preinitializer_path
@@ -44,6 +43,7 @@ module Rails
   class VendorBoot &lt; Boot
     def load_initializer
       require &quot;#{RAILS_ROOT}/vendor/rails/railties/lib/initializer&quot;
+      Rails::Initializer.run(:install_gem_spec_stubs)
     end
   end
 </diff>
      <filename>blog/config/boot.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,4 @@
-RAILS_GEM_VERSION = '2.0.2' unless defined? RAILS_GEM_VERSION
+RAILS_GEM_VERSION = '2.0.991' unless defined? RAILS_GEM_VERSION
 
 require File.join(File.dirname(__FILE__), 'boot')
 
@@ -8,5 +8,11 @@ Rails::Initializer.run do |config|
     :session_key =&gt; '_blog_demo_session',
     :secret      =&gt; '2f60d1ea840a895f406b30276c7dfe47ac86fbebf345be8c9d5f66487a9c30985a62216347ea71003a9c4686095eb99cf895455ffd5b5c36413fe49a83ebe3b7'
   }
-end
-#require 'ruport'
\ No newline at end of file
+  
+  config.gem &quot;haml&quot;, :version =&gt; &quot;1.8&quot;
+  config.gem &quot;launchy&quot;
+  config.gem &quot;defunkt-github&quot;, :lib =&gt; 'github', :source =&gt; &quot;http://gems.github.com&quot;
+  config.gem &quot;rmagick&quot;, :lib =&gt; &quot;RMagick2&quot;
+  
+  config.time_zone = 'UTC'
+end
\ No newline at end of file</diff>
      <filename>blog/config/environment.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,18 @@
 ActionController::Routing::Routes.draw do |map|
+  map.resources :roles
+
+  map.resources :users
+
+  map.resource :session
+
   map.root :controller =&gt; 'posts'
   map.resources :posts, :has_many =&gt; :comments
   map.namespace :admin do |admin|
     admin.resources :posts
   end
+  
+  map.signup '/signup', :controller =&gt; 'users', :action =&gt; 'new'
+  map.login  '/login',  :controller =&gt; 'sessions', :action =&gt; 'new'
+  map.logout '/logout', :controller =&gt; 'sessions', :action =&gt; 'destroy'
+  
 end
\ No newline at end of file</diff>
      <filename>blog/config/routes.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
 //           (c) 2005-2007 Ivan Krstic (http://blogs.law.harvard.edu/ivan)
 //           (c) 2005-2007 Jon Tirsen (http://www.tirsen.com)
 // Contributors:</diff>
      <filename>blog/public/javascripts/controls.js</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
 //           (c) 2005-2007 Sammi Williams (http://www.oriontransfer.co.nz, sammi@oriontransfer.co.nz)
 // 
 // script.aculo.us is freely distributable under the terms of an MIT-style license.</diff>
      <filename>blog/public/javascripts/dragdrop.js</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
 // Contributors:
 //  Justin Palmer (http://encytemedia.com/)
 //  Mark Pilgrim (http://diveintomark.org/)</diff>
      <filename>blog/public/javascripts/effects.js</filename>
    </modified>
    <modified>
      <diff>@@ -1,13 +1,28 @@
 DEFAULTS: &amp;DEFAULTS
-  created_at: &lt;%= Time.now %&gt;
-  updated_at: &lt;%= Time.now %&gt;
+  created_at: &lt;%= Time.now.to_s(:db) %&gt;
+  updated_at: &lt;%= Time.now.to_s(:db) %&gt;
 
 comment_one:
   post: post_one
-  body: MyText
+  body: MyText1
   &lt;&lt;: *DEFAULTS
 
 comment_two:
+  post: post_one
+  body: MyText2
+  &lt;&lt;: *DEFAULTS
+
+comment_three:
+  post: post_one
+  body: MyText3
+  &lt;&lt;: *DEFAULTS
+
+comment_four:
+  post: post_one
+  body: MyText4
+  &lt;&lt;: *DEFAULTS
+  
+comment_five:
   post: post_two
-  body: MyText
+  body: MyText5
   &lt;&lt;: *DEFAULTS
\ No newline at end of file</diff>
      <filename>blog/test/fixtures/comments.yml</filename>
    </modified>
    <modified>
      <diff>@@ -1,13 +1,35 @@
-DEFAULTS: &amp;DEFAULTS
-  created_at: &lt;%= Time.now %&gt;
-  updated_at: &lt;%= Time.now %&gt;
-  
 post_one:
-  title: MyString
+  title: Hello World
   body: MyText
-  &lt;&lt;: *DEFAULTS
+  created_at: &lt;%= (Time.now - 1.week).to_s(:db) %&gt;
+  updated_at: &lt;%= (Time.now - 1.week).to_s(:db) %&gt;
 
 post_two:
-  title: MyString
+  title: Hello Brazil
   body: MyText
-  &lt;&lt;: *DEFAULTS
\ No newline at end of file
+  created_at: &lt;%= (Time.now - 2.weeks).to_s(:db)%&gt;
+  updated_at: &lt;%= (Time.now - 2.weeks).to_s(:db)%&gt;
+
+post_three:
+ title: Hello RailsConf
+ body: MyText
+ created_at: &lt;%= (Time.now).to_s(:db)%&gt;
+ updated_at: &lt;%= (Time.now).to_s(:db)%&gt;
+ 
+post_four:
+ title: Rails 2.1
+ body: 
+ created_at: &lt;%= (Time.now).to_s(:db)%&gt;
+ updated_at: &lt;%= (Time.now).to_s(:db)%&gt;
+
+post_five:
+ title: RailsCasts
+ body: 
+ created_at: &lt;%= (Time.now - 1.week).to_s(:db)%&gt;
+ updated_at: &lt;%= (Time.now - 1.week).to_s(:db)%&gt;
+
+post_five:
+ title: AkitaOnRails
+ body: 
+ created_at: &lt;%= (Time.now).to_s(:db)%&gt;
+ updated_at: &lt;%= (Time.now).to_s(:db)%&gt;
\ No newline at end of file</diff>
      <filename>blog/test/fixtures/posts.yml</filename>
    </modified>
    <modified>
      <diff>@@ -1,3 +1,6 @@
 class Post &lt; ActiveResource::Base
-  self.site = 'http://akita:akita@localhost:3000/admin'
+  self.site = 'http://localhost:3000/admin'
+  self.user = 'akita'
+  self.password = 'akita'
+  self.timeout = 5 # this is IMPORTANT!
 end
\ No newline at end of file</diff>
      <filename>blog_remote/app/models/post.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>6be4d1f8652f22758237843cb155e5f90b663fcf</id>
    </parent>
  </parents>
  <author>
    <name>Fabio Akita</name>
    <email>akitaonrails@akitaonrails.local</email>
  </author>
  <url>http://github.com/akitaonrails/rolling_with_rails_tutorial/commit/fe02037ea7843b0fbad57fc49cdab8d0b98bd33f</url>
  <id>fe02037ea7843b0fbad57fc49cdab8d0b98bd33f</id>
  <committed-date>2008-05-25T15:55:59-07:00</committed-date>
  <authored-date>2008-05-25T15:55:59-07:00</authored-date>
  <message>Rails 2.1 Tutorial</message>
  <tree>26c756ede06459c4434797e3828ba00a92cf0eba</tree>
  <committer>
    <name>Fabio Akita</name>
    <email>akitaonrails@akitaonrails.local</email>
  </committer>
</commit>
