friendly_id 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data.tar.gz.sig CHANGED
Binary file
data/History.txt CHANGED
@@ -1,3 +1,9 @@
1
+ == 2.0.1 2009-01-19
2
+
3
+ * 1 minor enhancements:
4
+ * Fix infinite redirect bug when using .has_better_id? in your controllers (Sean Abrahams)
5
+
6
+
1
7
  == 2.0.0 2009-01-03
2
8
 
3
9
  * 5 major enhancements:
@@ -5,8 +11,8 @@
5
11
  * Support for UTF-8 friendly_ids (Norman Clarke)
6
12
  * Can now be installed via Ruby Gems, or as a Rails plugin (Norman Clarke)
7
13
  * Improved handling of non-unique slugs (Norman Clarke and Adrian Mugnolo)
8
- * 2 minor enhancements:
9
- * Shoulda macro (Josh Nichols - http://github.com/technicalpickles)
14
+ * 2 minor enhancements:
15
+ * Shoulda macro (Josh Nichols)
10
16
  * Various small bugfixes, cleanups and refactorings
11
17
 
12
18
  == 2008-12-01
data/Manifest.txt CHANGED
@@ -3,6 +3,7 @@ MIT-LICENSE
3
3
  Manifest.txt
4
4
  README.rdoc
5
5
  Rakefile
6
+ config/website.yml
6
7
  friendly_id.gemspec
7
8
  generators/friendly_id/friendly_id_generator.rb
8
9
  generators/friendly_id/templates/create_slugs.rb
data/README.rdoc CHANGED
@@ -315,4 +315,4 @@ FriendlyId was created by {Norman Clarke}[mailto:norman@randomba.org],
315
315
  {Adrian Mugnolo}[mailto:adrian@randomba.org], and {Emilio Tagua}[mailto:miloops@gmail.com].
316
316
 
317
317
  Copyright (c) 2008 Norman Clarke, Adrian Mugnolo and Emilio Tagua, released
318
- under the MIT license.
318
+ under the MIT license.
data/Rakefile CHANGED
@@ -1,7 +1,7 @@
1
1
  require 'newgem'
2
2
  require 'lib/friendly_id/version'
3
3
 
4
- Hoe.new("friendly_id", FriendlyId::Version::STRING) do |p|
4
+ $hoe = Hoe.new("friendly_id", FriendlyId::Version::STRING) do |p|
5
5
  p.rubyforge_name = "friendly-id"
6
6
  p.author = ['Norman Clarke', 'Adrian Mugnolo', 'Emilio Tagua']
7
7
  p.email = ['norman@randomba.org', 'adrian@randomba.org', 'miloops@gmail.com']
@@ -20,6 +20,8 @@ Hoe.new("friendly_id", FriendlyId::Version::STRING) do |p|
20
20
  p.remote_rdoc_dir = ""
21
21
  end
22
22
 
23
+ require 'newgem/tasks'
24
+
23
25
  desc "Run RCov"
24
26
  task :rcov do
25
27
  run_coverage Dir["test/**/*_test.rb"]
@@ -0,0 +1,2 @@
1
+ host: compay@rubyforge.org
2
+ remote_dir: /var/www/gforge-projects/friendly-id
data/friendly_id.gemspec CHANGED
@@ -1,18 +1,19 @@
1
+ # -*- encoding: utf-8 -*-
2
+
1
3
  Gem::Specification.new do |s|
2
4
  s.name = %q{friendly_id}
3
- s.version = "2.0.0"
5
+ s.version = "2.0.1"
4
6
 
5
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
6
8
  s.authors = ["Norman Clarke", "Adrian Mugnolo", "Emilio Tagua"]
7
- s.cert_chain = ["/Users/norman/.gem/gem-public_cert.pem"]
8
- s.date = %q{2008-12-30}
9
+ s.date = %q{2009-01-19}
9
10
  s.description = %q{A comprehensive slugging and pretty-URL plugin for Ruby on Rails.}
10
11
  s.email = ["norman@randomba.org", "adrian@randomba.org", "miloops@gmail.com"]
11
- s.extra_rdoc_files = ["History.txt", "Manifest.txt"]
12
+ s.extra_rdoc_files = ["History.txt", "Manifest.txt", "README.rdoc"]
12
13
  s.files = ["History.txt", "MIT-LICENSE", "Manifest.txt", "README.rdoc", "Rakefile", "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/helpers.rb", "lib/friendly_id/non_sluggable_class_methods.rb", "lib/friendly_id/non_sluggable_instance_methods.rb", "lib/friendly_id/shoulda_macros.rb", "lib/friendly_id/slug.rb", "lib/friendly_id/sluggable_class_methods.rb", "lib/friendly_id/sluggable_instance_methods.rb", "lib/friendly_id/version.rb", "lib/tasks/friendly_id.rake", "lib/tasks/friendly_id.rb", "test/database.yml", "test/fixtures/countries.yml", "test/fixtures/country.rb", "test/fixtures/people.yml", "test/fixtures/person.rb", "test/fixtures/post.rb", "test/fixtures/posts.yml", "test/fixtures/slugs.yml", "test/fixtures/user.rb", "test/fixtures/users.yml", "test/non_slugged_test.rb", "test/rails/2.x/app/controllers/application.rb", "test/rails/2.x/config/boot.rb", "test/rails/2.x/config/database.yml", "test/rails/2.x/config/environment.rb", "test/rails/2.x/config/environments/test.rb", "test/rails/2.x/config/routes.rb", "test/schema.rb", "test/scoped_model_test.rb", "test/slug_test.rb", "test/sluggable_test.rb", "test/test_helper.rb"]
13
14
  s.has_rdoc = true
14
15
  s.homepage = %q{http://randomba.org}
15
- s.rdoc_options = ["--main", "README.txt"]
16
+ s.rdoc_options = ["--main", "README.rdoc"]
16
17
  s.require_paths = ["lib"]
17
18
  s.rubyforge_project = %q{friendly-id}
18
19
  s.rubygems_version = %q{1.3.1}
@@ -26,13 +27,16 @@ Gem::Specification.new do |s|
26
27
 
27
28
  if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
28
29
  s.add_runtime_dependency(%q<unicode>, [">= 0.1"])
29
- s.add_development_dependency(%q<hoe>, [">= 1.8.2"])
30
+ s.add_development_dependency(%q<newgem>, [">= 1.2.3"])
31
+ s.add_development_dependency(%q<hoe>, [">= 1.8.0"])
30
32
  else
31
33
  s.add_dependency(%q<unicode>, [">= 0.1"])
32
- s.add_dependency(%q<hoe>, [">= 1.8.2"])
34
+ s.add_dependency(%q<newgem>, [">= 1.2.3"])
35
+ s.add_dependency(%q<hoe>, [">= 1.8.0"])
33
36
  end
34
37
  else
35
38
  s.add_dependency(%q<unicode>, [">= 0.1"])
36
- s.add_dependency(%q<hoe>, [">= 1.8.2"])
39
+ s.add_dependency(%q<newgem>, [">= 1.2.3"])
40
+ s.add_dependency(%q<hoe>, [">= 1.8.0"])
37
41
  end
38
42
  end
data/lib/friendly_id.rb CHANGED
@@ -60,7 +60,6 @@ module FriendlyId
60
60
 
61
61
  end
62
62
 
63
-
64
63
  end
65
64
 
66
65
  if defined?(ActiveRecord)
@@ -81,7 +81,8 @@ module FriendlyId::SluggableInstanceMethods
81
81
 
82
82
  def init_finder_slug
83
83
  return false if !@finder_slug_name
84
- slug = Slug.find(:first, :conditions => {:sluggable_id => id, :name => @finder_slug_name, :sluggable_type => self.class.name })
84
+ name, sequence = Slug.parse(@finder_slug_name)
85
+ slug = Slug.find(:first, :conditions => {:sluggable_id => id, :name => name, :sequence => sequence, :sluggable_type => self.class.name })
85
86
  finder_slug = slug
86
87
  end
87
88
 
@@ -2,7 +2,7 @@ module FriendlyId #:nodoc:
2
2
  module Version #:nodoc:
3
3
  MAJOR = 2
4
4
  MINOR = 0
5
- TINY = 0
5
+ TINY = 1
6
6
  STRING = [MAJOR, MINOR, TINY].join('.')
7
7
  end
8
8
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: friendly_id
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Norman Clarke
@@ -32,7 +32,7 @@ cert_chain:
32
32
  h7fbBRfStxI=
33
33
  -----END CERTIFICATE-----
34
34
 
35
- date: 2009-01-04 00:00:00 -02:00
35
+ date: 2009-01-19 00:00:00 -02:00
36
36
  default_executable:
37
37
  dependencies:
38
38
  - !ruby/object:Gem::Dependency
@@ -84,6 +84,7 @@ files:
84
84
  - Manifest.txt
85
85
  - README.rdoc
86
86
  - Rakefile
87
+ - config/website.yml
87
88
  - friendly_id.gemspec
88
89
  - generators/friendly_id/friendly_id_generator.rb
89
90
  - generators/friendly_id/templates/create_slugs.rb
metadata.gz.sig CHANGED
Binary file