<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>generators/friendly_id_20_upgrade/friendly_id_20_upgrade_generator.rb</filename>
    </added>
    <added>
      <filename>generators/friendly_id_20_upgrade/templates/upgrade_friendly_id_to_20.rb</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -1,6 +1,7 @@
 == RELEASE DATE COMING SOON
 
 * FriendlyId 2.0 Released
+
   * Support for scoped slugs (Norman Clarke)
   * Support for UTF-8 friendly_ids (Norman Clarke)
   * Can now be installed via Ruby Gems, or as a Rails plugin (Norman Clarke)</diff>
      <filename>History.txt</filename>
    </modified>
    <modified>
      <diff>@@ -16,6 +16,8 @@ coverage/rails-init_rb.html
 friendly_id.gemspec
 generators/friendly_id/friendly_id_generator.rb
 generators/friendly_id/templates/create_slugs.rb
+generators/friendly_id_20_upgrade/friendly_id_20_upgrade_generator.rb
+generators/friendly_id_20_upgrade/templates/upgrade_friendly_id_to_20.rb
 init.rb
 lib/friendly_id.rb
 lib/friendly_id/non_sluggable_class_methods.rb</diff>
      <filename>Manifest.txt</filename>
    </modified>
    <modified>
      <diff>@@ -86,15 +86,27 @@ numeric id, or with an outdated slug.
 
 === Slug Versioning
 
-FriendlyId will record changes to slugs so that you can tell when the model
-is found with an older slug. This can be useful if you want to do a 301
-redirect to your updated URL.
+FriendlyId will record changes to slugs so that you can tell when the model is
+found with an older slug, or by the numeric id. This can be useful if you want
+to do a 301 redirect to your updated URL.
+
+  class PostsController &lt; ApplicationController
+
+    before_filter ensure_current_post_url, :only =&gt; :show
+
+    ...
+
+    def ensure_current_post_url
+      redirect_to @post, :status =&gt; :moved_permanently if @post.has_better_id?
+    end
 
-  def find_record_using_friendly_id
-    @post = Post.find(params[:id])
-    redirect_to @post, :status =&gt; :moved_permanently if @post.has_better_id?
   end
 
+This is particularly useful when implementing FrindlyId on an existing
+website that already has many URL's with the old numeric id listed on search
+engines. When the search engine spiders crawl your site, they will
+eventually pick up the new, more SEO-friendly URL's.
+
 === Non-unique Slug Names
 
 FriendlyId will append a arbitrary number to the end of the id to keep it
@@ -112,9 +124,6 @@ rest of the slug. This is important to enable having slugs like:
   /cars/peugeot-206
   /cars/peugeot-206--2
 
-This is somewhat ugly, but you can change the &quot;--&quot; for another character or
-sequence of characters if you wish.
-
 === Reserved Names
 
 You can mark off some strings as reserved so that, for example, you don't end
@@ -204,7 +213,7 @@ that uses a non-Roman writing system, your feedback would be most welcome.
 
 FriendlyId is installed as a Ruby Gem:
 
-  gem install friendly-id
+  gem install friendly_id
 
 Alternatively, you can install it as a Rails plugin, though this is
 discouraged:
@@ -217,7 +226,7 @@ FriendlyId currently works with Rails 2.0.0 and higher. Here's how to set it up.
 
 1) Install the Gem:
 
-  sudo gem install friendly-id
+  sudo gem install friendly_id
   cd my_app
   script/generate friendly_id
   rake db:migrate
@@ -250,6 +259,39 @@ The default is to remove dead slugs older than 45 days, but is configurable:
 
 rake:friendly_id:remove_old_slugs MODEL=MyModelName DAYS=60
 
+== Upgrading from an older version
+
+If you installed an older version of FriendlyId and want to upgrade to 2.0,
+follow these steps:
+
+==== Install the friendly_id Gem:
+
+  sudo gem install friendly_id
+
+==== Add FriendlyId to environment.rb:
+
+===== For Rails 2.1 and higher:
+
+  config.gem &quot;friendly_id&quot;, :version =&gt; &quot;&gt;= 2.0.0&quot;
+
+===== For Rails 2.0:
+
+Add this to the bottom of environment.rb:
+
+  require 'friendly_id'
+
+==== Remove the older version of FriendlyId:
+
+  git rm -rf vendor/plugins/friendly_id
+  svn delete vendor/plugins/friendly_id
+  # or whatever
+
+====  Generate the upgrade migration and run it
+
+  ./script generate friendly_id_20_upgrade
+  rake db:migrate
+
+That's it!
 
 == Hacking FriendlyId:
 
@@ -260,6 +302,7 @@ we love pull requests. :-)
 
 Please report them on Lighthouse[http://randomba.lighthouseapp.com/projects/14675-friendly_id].
 
+
 == Credits:
 
 FriendlyId was created by {Norman Clarke}[mailto:norman@randomba.org],</diff>
      <filename>README.rdoc</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>893d08d6e6568f0b78d00188500409f90aa7d554</id>
    </parent>
  </parents>
  <author>
    <name>Norman Clarke</name>
    <email>norman@randomba.org</email>
  </author>
  <url>http://github.com/norman/friendly_id/commit/a77ee1446d108cbd3e0323341460c1ed4a0dfe44</url>
  <id>a77ee1446d108cbd3e0323341460c1ed4a0dfe44</id>
  <committed-date>2008-12-19T06:22:22-08:00</committed-date>
  <authored-date>2008-12-19T05:04:02-08:00</authored-date>
  <message>Added upgrade migration. Tweaked README.</message>
  <tree>ef9b270e24b1ed9b0b4a2ffe53bc88b59d366039</tree>
  <committer>
    <name>Norman Clarke</name>
    <email>norman@randomba.org</email>
  </committer>
</commit>
